fix coverity error

Change-Id: Ie0b059c887404c05576f24b6e16e9c9bae3d1ebd
Signed-off-by: Eyal Salomon <esalomon@mellanox.com>