Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--winsup/cygwin/ChangeLog8
-rw-r--r--winsup/cygwin/Makefile.in2
-rw-r--r--winsup/cygwin/fhandler.h22
-rw-r--r--winsup/cygwin/select.cc1
4 files changed, 21 insertions, 12 deletions
diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog
index a12d86609..14d77c050 100644
--- a/winsup/cygwin/ChangeLog
+++ b/winsup/cygwin/ChangeLog
@@ -1,5 +1,13 @@
2001-11-01 Christopher Faylor <cgf@redhat.com>
+ * fhandler.h: Change Windows 'BOOL's to c++ 'bool's for all variables.
+ * select.cc (fhandler_base::ready_for_read): Set read_ready to zero
+ prior to testing it or it will be uninitialized.
+
+ * Makefile.in (CFLAGS): Move setting to Makefile.common.
+
+2001-11-01 Christopher Faylor <cgf@redhat.com>
+
* cygheap.h (cygheap_fdmanip::isopen): Set appropriate errno if fd not
open.
* select.cc (fhandler_base::ready_for_read): Release an open guard
diff --git a/winsup/cygwin/Makefile.in b/winsup/cygwin/Makefile.in
index 42d868363..ba29d1a67 100644
--- a/winsup/cygwin/Makefile.in
+++ b/winsup/cygwin/Makefile.in
@@ -50,7 +50,7 @@ DEFS = @DEFS@
CC:=@CC@
# FIXME: Which is it, CC or CC_FOR_TARGET?
CC_FOR_TARGET:=$(CC)
-CFLAGS:=@CFLAGS@ -Winline
+CFLAGS:=@CFLAGS@
CFLAGS+=-MD -fbuiltin
CXX:=@CXX@
CXXFLAGS:=@CXXFLAGS@
diff --git a/winsup/cygwin/fhandler.h b/winsup/cygwin/fhandler.h
index 9559a1468..76c3ff0bb 100644
--- a/winsup/cygwin/fhandler.h
+++ b/winsup/cygwin/fhandler.h
@@ -678,13 +678,13 @@ class fhandler_console: public fhandler_termios
int args_[MAXARGS];
int nargs_;
unsigned rarg;
- BOOL saw_question_mark;
+ bool saw_question_mark;
char my_title_buf [TITLESIZE + 1];
WORD current_win32_attr;
ansi_intensity intensity;
- BOOL underline, blink, reverse;
+ bool underline, blink, reverse;
WORD fg, bg;
/* saved cursor coordinates */
@@ -712,9 +712,9 @@ class fhandler_console: public fhandler_termios
DWORD dwLastButtonState;
int nModifiers;
- BOOL insert_mode;
- BOOL use_mouse;
- BOOL raw_win32_keyboard_mode;
+ bool insert_mode;
+ bool use_mouse;
+ bool raw_win32_keyboard_mode;
/* Output calls */
void set_default_attr ();
@@ -966,7 +966,7 @@ class fhandler_dev_clipboard: public fhandler_base
off_t pos;
void *membuffer;
size_t msize;
- BOOL eof;
+ bool eof;
};
class fhandler_windows: public fhandler_base
@@ -1044,10 +1044,10 @@ struct select_record
int fd;
HANDLE h;
fhandler_base *fh;
- BOOL saw_error;
- BOOL windows_handle;
- BOOL read_ready, write_ready, except_ready;
- BOOL read_selected, write_selected, except_selected;
+ bool saw_error;
+ bool windows_handle;
+ bool read_ready, write_ready, except_ready;
+ bool read_selected, write_selected, except_selected;
int (*startup) (select_record *me, class select_stuff *stuff);
int (*poll) (select_record *me, fd_set *readfds, fd_set *writefds,
fd_set *exceptfds);
@@ -1073,7 +1073,7 @@ class select_stuff
{
memset (device_specific, 0, sizeof (device_specific));
}
- BOOL always_ready, windows_used;
+ bool always_ready, windows_used;
select_record start;
void *device_specific[FH_NDEV];
diff --git a/winsup/cygwin/select.cc b/winsup/cygwin/select.cc
index bcfc56f02..1ba3ef3d8 100644
--- a/winsup/cygwin/select.cc
+++ b/winsup/cygwin/select.cc
@@ -1074,6 +1074,7 @@ fhandler_base::ready_for_read (int fd, DWORD howlong, int ignra)
{
int avail = 0;
select_record me (this);
+ me.read_ready = false;
me.fd = fd;
while (!avail)
{