Fix potential crash in TCPTransportSocket
Fix potential crash in TCPTransportSocket

Fix a potential crash by guarding the different steps of connection: onResolve
could crash if a disconnection was requested before its end.

Change-Id: I1e81b53032890d5da16c14f950955aa8ac1922ff
Reviewed-on: http://gerrit.aldebaran.lan/52323
Reviewed-by: tfontenay <c24d15a4b18b5a000d37b3d79586313e143f61c8@aldebaran-robotics.com>
Reviewed-by: pdaouadi <fc1eb3334d3fdad315bae23aa166bc70bd434067@aldebaran-robotics.com>
Approved: tfontenay <c24d15a4b18b5a000d37b3d79586313e143f61c8@aldebaran-robotics.com>
Tested-by: tfontenay <c24d15a4b18b5a000d37b3d79586313e143f61c8@aldebaran-robotics.com>

bsautron/libqi,aldebaran/libqi,aldebaran/libqi,aldebaran/libqi,vbarbaresi/libqi