telemetry: check socket creation failure
authorCiara Power <ciara.power@intel.com>
Tue, 12 May 2020 15:29:01 +0000 (16:29 +0100)
committerThomas Monjalon <thomas@monjalon.net>
Tue, 19 May 2020 13:05:56 +0000 (15:05 +0200)
commit07580a734b99df9984da47a5ea844ba65d69f929
treeaff0086937054808519293d07d11389bfedaf6ec
parent6aa1aa0ebc48c14dd90648e2dbb726f0f09c4674
telemetry: check socket creation failure

The return value from the socket function is now checked, as it can
return a negative value on error.

Coverity issue: 358443
Fixes: b80fe1805eee ("telemetry: introduce backward compatibility")

Signed-off-by: Ciara Power <ciara.power@intel.com>
Acked-by: Kevin Laatz <kevin.laatz@intel.com>
lib/librte_telemetry/telemetry_legacy.c