From 9895091d0dfe5b05f86a7c78a8ee3f4a396a0121 Mon Sep 17 00:00:00 2001 From: Christopher Faylor Date: Thu, 22 Jan 2009 16:00:58 +0000 Subject: [PATCH] * select.cc (peek_serial): Add hack to allow proper operation with com0com driver. --- winsup/cygwin/ChangeLog | 5 +++++ winsup/cygwin/select.cc | 4 ++++ 2 files changed, 9 insertions(+) diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog index 11eefb75a..bdd910456 100644 --- a/winsup/cygwin/ChangeLog +++ b/winsup/cygwin/ChangeLog @@ -1,3 +1,8 @@ +2009-01-22 Christopher Faylor + + * select.cc (peek_serial): Add hack to allow proper operation with + com0com driver. + 2009-01-21 Corinna Vinschen Remove USE_SERVER define. Accommodate throughout. diff --git a/winsup/cygwin/select.cc b/winsup/cygwin/select.cc index eceeeafcb..da54da5a1 100644 --- a/winsup/cygwin/select.cc +++ b/winsup/cygwin/select.cc @@ -928,6 +928,10 @@ peek_serial (select_record *s, bool) goto out; } + /* This is apparently necessary for the com0com driver. + See: http://cygwin.com/ml/cygwin/2009-01/msg00667.html */ + SetCommMask (h, 0); + SetCommMask (h, EV_RXCHAR); if (!fh->overlapped_armed)