From: dje@canuck.cygnus.com (Doug Evans)
Subject: Re: Bug in fhanler.cc (beta 17).
17 Dec 1996 08:39:50 -0800
Sender: daemon@cygnus.com
Approved: cygnus.gnu-win32@cygnus.com
Distribution: cygnus
Message-ID: <199612171608.IAA03298.cygnus.gnu-win32@canuck.cygnus.com>
Original-To: sos@prospect.com.ru
Original-CC: noer@cygnus.com, gnu-win32@cygnus.com
In-reply-to: <01BBEC32.23A55BA0@bbs.prospect.com.ru> (message from Sergey
	Okhapkin on Tue, 17 Dec 1996 15: 42:41 +0300)
Original-Sender: owner-gnu-win32@cygnus.com

   From: Sergey Okhapkin <sos@prospect.com.ru>
   Date: Tue, 17 Dec 1996 15:42:41 +0300

   Fhandler.cc in winsup directory has a bug in function FakeReadFile - when 
   application tries to read character from console in binary mode, and there 
   is no console input events in console input buffer, this function hangs. 
   The following patch corrects this problem:

   *** fhandler.cc.orig    Wed Dec 11 02:39:41 1996
   --- fhandler.cc Tue Dec 17 15:22:25 1996
   ***************
   *** 2267,2273 ****
	       return 0;           /* seems to be failure */
	     }
	   /* doc says it will return at least one event... */
   !       num_events--;
	   /* check if we're just disposing of this one */

	   if (input_rec.EventType != KEY_EVENT)
   --- 2267,2274 ----
	       return 0;           /* seems to be failure */
	     }
	   /* doc says it will return at least one event... */
   !       if(num_events)
   !         num_events--;
	   /* check if we're just disposing of this one */

	   if (input_rec.EventType != KEY_EVENT)

   After applying this patch, Lynx2-5 works fine with cygwin.

Thanks.  This is the kind of thing I'd *love* to see a lot more of!
Keep 'em coming. :-)
-
For help on using this list, send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".
