]> asedeno.scripts.mit.edu Git - PuTTY.git/commit
Grow some nasty warts on the side of winhandl.c, in preparation for
authorSimon Tatham <anakin@pobox.com>
Sun, 27 Aug 2006 10:00:36 +0000 (10:00 +0000)
committerSimon Tatham <anakin@pobox.com>
Sun, 27 Aug 2006 10:00:36 +0000 (10:00 +0000)
commit17bc6545327276030423ada8a95dc45f365bf2ad
treefaa205e0eead3c37c7f8d095fdaee51c19afdcca
parent3dc4063f692c01d78701934ad4b9333251ca6faf
Grow some nasty warts on the side of winhandl.c, in preparation for
a serial port backend:
 - In order to do simultaneous reading and writing on the same
   HANDLE, you must enable overlapped access and pass an OVERLAPPED
   structure to each ReadFile and WriteFile call. This would make
   sense if it were an optional thing I could do if I wanted to do
   the reading and writing in the same thread, but making it
   mandatory even if I'm doing them in _different_ threads is just
   annoying and arbitrary.
 - Serial ports occasionally return length 0 from ReadFile, for no
   particularly good reason. Fortunately serial ports also don't
   have a real EOF condition to speak of, so ignoring EOFs is
   actually a viable response in spite of sounding utterly gross.
Hence, handle_{input,output}_new() now accept a flags parameter,
which includes a flag to enable the OVERLAPPED bureaucracy and a
flag to cause EOFs to be ignored on input handles. The current
clients of winhandl.c do not use either of these.

[originally from svn r6813]
windows/winhandl.c
windows/winplink.c
windows/winproxy.c
windows/winstuff.h