From 0a73fce00ca7f208a5dcdd26d33be70d705fc276 Mon Sep 17 00:00:00 2001 From: Corinna Vinschen Date: Wed, 24 Jul 2002 11:01:37 +0000 Subject: [PATCH] * fhandler_serial.cc: Change 'must_init_serial_line capability' to 'supports_reading_modem_output_lines' throughout (negated meaning). * wincap.cc: Ditto. * wincap.h: Ditto. --- winsup/cygwin/ChangeLog | 7 +++++++ winsup/cygwin/fhandler_serial.cc | 4 ++-- winsup/cygwin/wincap.cc | 22 +++++++++++----------- winsup/cygwin/wincap.h | 4 ++-- 4 files changed, 22 insertions(+), 15 deletions(-) diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog index 0be0cdce6..9888c2a29 100644 --- a/winsup/cygwin/ChangeLog +++ b/winsup/cygwin/ChangeLog @@ -1,3 +1,10 @@ +2002-07-24 Corinna Vinschen + + * fhandler_serial.cc: Change 'must_init_serial_line capability' + to 'supports_reading_modem_output_lines' throughout (negated meaning). + * wincap.cc: Ditto. + * wincap.h: Ditto. + 2002-07-23 Nicholas Wourms * cygwin.din (fcloseall): Add symbol for export. diff --git a/winsup/cygwin/fhandler_serial.cc b/winsup/cygwin/fhandler_serial.cc index 67e11908f..748eb4b28 100644 --- a/winsup/cygwin/fhandler_serial.cc +++ b/winsup/cygwin/fhandler_serial.cc @@ -272,7 +272,7 @@ fhandler_serial::open (path_conv *, int flags, mode_t mode) request TIOCMGET could return correct value of RTS and DTR lines. Important only for Win 9x systems */ - if (wincap.must_init_serial_line ()) + if (!wincap.supports_reading_modem_output_lines ()) { if (EscapeCommFunction (get_handle (), SETDTR) == 0) system_printf ("couldn't set initial state of DTR for %s, %E", get_name ()); @@ -409,7 +409,7 @@ fhandler_serial::ioctl (unsigned int cmd, void *buffer) modemStatus |= TIOCM_RI; if (modemLines & MS_RLSD_ON) modemStatus |= TIOCM_CD; - if (wincap.must_init_serial_line ()) + if (!wincap.supports_reading_modem_output_lines ()) modemStatus |= rts | dtr; else { diff --git a/winsup/cygwin/wincap.cc b/winsup/cygwin/wincap.cc index 69333375d..a702bfeea 100644 --- a/winsup/cygwin/wincap.cc +++ b/winsup/cygwin/wincap.cc @@ -46,7 +46,7 @@ static NO_COPY wincaps wincap_unknown = { has_valid_processorlevel:false, has_64bit_file_access:false, has_process_io_counters:false, - must_init_serial_line:true, + supports_reading_modem_output_lines:false, }; static NO_COPY wincaps wincap_95 = { @@ -84,7 +84,7 @@ static NO_COPY wincaps wincap_95 = { has_valid_processorlevel:false, has_64bit_file_access:false, has_process_io_counters:false, - must_init_serial_line:true, + supports_reading_modem_output_lines:false, }; static NO_COPY wincaps wincap_95osr2 = { @@ -122,7 +122,7 @@ static NO_COPY wincaps wincap_95osr2 = { has_valid_processorlevel:false, has_64bit_file_access:false, has_process_io_counters:false, - must_init_serial_line:true, + supports_reading_modem_output_lines:false, }; static NO_COPY wincaps wincap_98 = { @@ -160,7 +160,7 @@ static NO_COPY wincaps wincap_98 = { has_valid_processorlevel:true, has_64bit_file_access:false, has_process_io_counters:false, - must_init_serial_line:true, + supports_reading_modem_output_lines:false, }; static NO_COPY wincaps wincap_98se = { @@ -198,7 +198,7 @@ static NO_COPY wincaps wincap_98se = { has_valid_processorlevel:true, has_64bit_file_access:false, has_process_io_counters:false, - must_init_serial_line:true, + supports_reading_modem_output_lines:false, }; static NO_COPY wincaps wincap_me = { @@ -236,7 +236,7 @@ static NO_COPY wincaps wincap_me = { has_valid_processorlevel:true, has_64bit_file_access:false, has_process_io_counters:false, - must_init_serial_line:true, + supports_reading_modem_output_lines:false, }; static NO_COPY wincaps wincap_nt3 = { @@ -274,7 +274,7 @@ static NO_COPY wincaps wincap_nt3 = { has_valid_processorlevel:true, has_64bit_file_access:true, has_process_io_counters:false, - must_init_serial_line:false, + supports_reading_modem_output_lines:true, }; static NO_COPY wincaps wincap_nt4 = { @@ -312,7 +312,7 @@ static NO_COPY wincaps wincap_nt4 = { has_valid_processorlevel:true, has_64bit_file_access:true, has_process_io_counters:false, - must_init_serial_line:false, + supports_reading_modem_output_lines:true, }; static NO_COPY wincaps wincap_nt4sp4 = { @@ -350,7 +350,7 @@ static NO_COPY wincaps wincap_nt4sp4 = { has_valid_processorlevel:true, has_64bit_file_access:true, has_process_io_counters:false, - must_init_serial_line:false, + supports_reading_modem_output_lines:true, }; static NO_COPY wincaps wincap_2000 = { @@ -388,7 +388,7 @@ static NO_COPY wincaps wincap_2000 = { has_valid_processorlevel:true, has_64bit_file_access:true, has_process_io_counters:true, - must_init_serial_line:false, + supports_reading_modem_output_lines:true, }; static NO_COPY wincaps wincap_xp = { @@ -426,7 +426,7 @@ static NO_COPY wincaps wincap_xp = { has_valid_processorlevel:true, has_64bit_file_access:true, has_process_io_counters:true, - must_init_serial_line:false, + supports_reading_modem_output_lines:true, }; wincapc wincap; diff --git a/winsup/cygwin/wincap.h b/winsup/cygwin/wincap.h index c2a4af872..c24b36ae5 100644 --- a/winsup/cygwin/wincap.h +++ b/winsup/cygwin/wincap.h @@ -47,7 +47,7 @@ struct wincaps unsigned has_valid_processorlevel : 1; unsigned has_64bit_file_access : 1; unsigned has_process_io_counters : 1; - unsigned must_init_serial_line : 1; + unsigned supports_reading_modem_output_lines : 1; }; class wincapc @@ -99,7 +99,7 @@ public: bool IMPLEMENT (has_valid_processorlevel) bool IMPLEMENT (has_64bit_file_access) bool IMPLEMENT (has_process_io_counters) - bool IMPLEMENT (must_init_serial_line) + bool IMPLEMENT (supports_reading_modem_output_lines) #undef IMPLEMENT };