Grow some nasty warts on the side of winhandl.c, in preparation for
authorsimon <simon@cda61777-01e9-0310-a592-d414129be87e>
Sun, 27 Aug 2006 10:00:36 +0000 (10:00 +0000)
committersimon <simon@cda61777-01e9-0310-a592-d414129be87e>
Sun, 27 Aug 2006 10:00:36 +0000 (10:00 +0000)
commitbdebd7e98958c2c61b3bcaed14129e5b7d68b589
treefaa205e0eead3c37c7f8d095fdaee51c19afdcca
parent9109d3fa28e92aa62710ed4cc3d581147acbdb04
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.

git-svn-id: svn://svn.tartarus.org/sgt/putty@6813 cda61777-01e9-0310-a592-d414129be87e
windows/winhandl.c
windows/winplink.c
windows/winproxy.c
windows/winstuff.h