This is the mail archive of the
cygwin@cygwin.com
mailing list for the Cygwin project.
1.3.2 non-blocking serial read is blocking
- To: "'cygwin at cygwin dot com'" <cygwin at cygwin dot com>
- Subject: 1.3.2 non-blocking serial read is blocking
- From: Anthony Pighin <apighin at Catena dot com>
- Date: Wed, 4 Jul 2001 13:20:53 -0400
This seems to be similar to the problem Christopher Faylor and Dan Morris
were discussing in:
http://sources.redhat.com/ml/cygwin-developers/2000-12/msg00064.html
I have upgraded to the latest 1.3.2 DLL, but the problem (if it is the same)
persists.
This is my first submission, so I hope I provide enough information. I am
enclosing a .C file which should show the problem. The program is a simple
infinite loop. The system is configured to be non-blocking, and does
constant polling of the serial port. However, once the first character is
received, the system blocks on the next read. The code is not dead, because
if more characters are sent, the system receives them.
I have tried to use ioctl(..., FIONREAD, ...), to check if there are
character to read before trying, but Cygwin does not support this.
Regards, and thanks,
Anthony
Encl.
<<serial.c>>
serial.c
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/