]> asedeno.scripts.mit.edu Git - PuTTY.git/commit
Completely remove the 'frozen_readable' mechanism from uxnet.c. It
authorSimon Tatham <anakin@pobox.com>
Sun, 21 Jul 2013 07:40:36 +0000 (07:40 +0000)
committerSimon Tatham <anakin@pobox.com>
Sun, 21 Jul 2013 07:40:36 +0000 (07:40 +0000)
commit7426b8f2158f7c2495faa3704a3c34a9be32901c
tree1a432dfbcd6f6f5c9a16ea9f107ee3092d707198
parent77791de4e179af27adc5557a76605827e8ac19ab
Completely remove the 'frozen_readable' mechanism from uxnet.c. It
parallels a similar mechanism in winnet.c and came over by copy and
paste, but is pointless in the Unix networking API.

On Windows, if you're using a mechanism such as WSAAsyncSelect which
delivers readability notifications as messages rather than return
values from a system call, you only get notified that a socket is
readable once - it remembers that it's told you, and doesn't tell you
again until after you've done a read. So in the case where we
intentionally stop reading from a socket because our local buffer is
full, and later want to start reading again, we do a read from the
socket with MSG_PEEK set, and that clears Windows's flag and tells it
to start sending us readability notifications again.

On Unix, select() and friends didn't do anything so strange in the
first place, so the whole mechanism is unnecessary.

[originally from svn r9951]
unix/uxnet.c