Wilfried Mestdagh wrote: >> Sorry mixed it up with with a 0 result 0 means a closed connection, >> -1 means an error, check LastError. > > Correct that it is an error, but no need to check LastError. TWSocket > take care of the error if it happens here. Just Exit OnDataAvailable > when Receive returns <= 0.
That's very true! Jack reported a freeze, so it might have been usefull to know the Winsock error number, eventhough not any error is a real error :-) --- Arno Garrels [TeamICS] http://www.overbyte.be/eng/overbyte/teamics.html -- To unsubscribe or change your settings for TWSocket mailing list please goto http://www.elists.org/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be