Hi,
I am working on a client socket application that uses multiple sockets in
forked processes.
Intermittently I am seeing the SocketClosed exception signalled from
SocketAbstract>>waitOn: when there are still bytes that can be received from
the socket.
Quoting:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winsock/wsapiref_6jn6.asp
"FD_CLOSE should only be posted after all data is read from a socket, but an
application should check for remaining data upon receipt of FD_CLOSE to
avoid any possibility of losing data"
I think I am seeing the "shoudn't" case :)
Should Socket>>onAsyncClose be implemented to send #onAsyncRead? If a
process is waiting on the readSemaphore it will cause the SocketClosed
exception to be signalled from Socket>>basicReceiveByteArray: instead.
I have been testing this without seeing any side effects, but I do not have
any code that relies on the #remoteSocketClosed event.
Thanks,
Steve Waring