François Piette wrote:
>> If I make a Send call to that socket, does it have to occur on the
>> same thread as the worker thread? Or can I call it's Send method
>> from another thread?  I looked at the WSocket.pas code and I didn't
>> see anything that looked like it wasn't thread-safe, 
> 
> Sending data pass thru the internal buffer which is protected by a
> critical section. So it should be thread safe.

Looking at the source it is IMO not safe since bAllSent variable
is not always protected by the critical section, this may lead to
race conditions if you ask me.

--
Arno Garrels 


--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be

Reply via email to