memory leak fixups

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