The Socket class is said not to be thread safe in the documentation.
Logicaly, that would mean that thread safety measures are required when
dealing with asyncronous socket operations. However, I have never seen any
exemple deal with locking the socket reference in asyncronous context. What
is the correct thing to do? Also, is there really any advantages to using
sockets through a NetworkStream? Is there a prefered model when dealing with
a binary protocol?
Thank you very much,
Etienne Boucher