From: Tor Lillqvist Date: Thu, 2 Jan 2003 00:30:22 +0000 (+0000) Subject: Correct the comment telling what headers have the declarations of some X-Git-Tag: GLIB_2_3_0~295 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=54cadf452898750ca813de0059dbc576f76e260b;p=platform%2Fupstream%2Fglib.git Correct the comment telling what headers have the declarations of some 2003-01-02 Tor Lillqvist * glib/gwin32.h: Correct the comment telling what headers have the declarations of some POSIXish functions. * glib/giowin32.c (g_io_win32_fd_get_flags_internal): Fix braino: The checks for readability/writeability were backwards. --- diff --git a/ChangeLog b/ChangeLog index 9d9a885..371b043 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2003-01-02 Tor Lillqvist + + * glib/gwin32.h: Correct the comment telling what headers have + the declarations of some POSIXish functions. + + * glib/giowin32.c (g_io_win32_fd_get_flags_internal): Fix braino: + The checks for readability/writeability were backwards. + 2003-01-01 Tor Lillqvist * glib/gmessages.c (ensure_stderr_valid): New function, parallel diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index 9d9a885..371b043 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -1,3 +1,11 @@ +2003-01-02 Tor Lillqvist + + * glib/gwin32.h: Correct the comment telling what headers have + the declarations of some POSIXish functions. + + * glib/giowin32.c (g_io_win32_fd_get_flags_internal): Fix braino: + The checks for readability/writeability were backwards. + 2003-01-01 Tor Lillqvist * glib/gmessages.c (ensure_stderr_valid): New function, parallel diff --git a/ChangeLog.pre-2-12 b/ChangeLog.pre-2-12 index 9d9a885..371b043 100644 --- a/ChangeLog.pre-2-12 +++ b/ChangeLog.pre-2-12 @@ -1,3 +1,11 @@ +2003-01-02 Tor Lillqvist + + * glib/gwin32.h: Correct the comment telling what headers have + the declarations of some POSIXish functions. + + * glib/giowin32.c (g_io_win32_fd_get_flags_internal): Fix braino: + The checks for readability/writeability were backwards. + 2003-01-01 Tor Lillqvist * glib/gmessages.c (ensure_stderr_valid): New function, parallel diff --git a/ChangeLog.pre-2-4 b/ChangeLog.pre-2-4 index 9d9a885..371b043 100644 --- a/ChangeLog.pre-2-4 +++ b/ChangeLog.pre-2-4 @@ -1,3 +1,11 @@ +2003-01-02 Tor Lillqvist + + * glib/gwin32.h: Correct the comment telling what headers have + the declarations of some POSIXish functions. + + * glib/giowin32.c (g_io_win32_fd_get_flags_internal): Fix braino: + The checks for readability/writeability were backwards. + 2003-01-01 Tor Lillqvist * glib/gmessages.c (ensure_stderr_valid): New function, parallel diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6 index 9d9a885..371b043 100644 --- a/ChangeLog.pre-2-6 +++ b/ChangeLog.pre-2-6 @@ -1,3 +1,11 @@ +2003-01-02 Tor Lillqvist + + * glib/gwin32.h: Correct the comment telling what headers have + the declarations of some POSIXish functions. + + * glib/giowin32.c (g_io_win32_fd_get_flags_internal): Fix braino: + The checks for readability/writeability were backwards. + 2003-01-01 Tor Lillqvist * glib/gmessages.c (ensure_stderr_valid): New function, parallel diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8 index 9d9a885..371b043 100644 --- a/ChangeLog.pre-2-8 +++ b/ChangeLog.pre-2-8 @@ -1,3 +1,11 @@ +2003-01-02 Tor Lillqvist + + * glib/gwin32.h: Correct the comment telling what headers have + the declarations of some POSIXish functions. + + * glib/giowin32.c (g_io_win32_fd_get_flags_internal): Fix braino: + The checks for readability/writeability were backwards. + 2003-01-01 Tor Lillqvist * glib/gmessages.c (ensure_stderr_valid): New function, parallel diff --git a/glib/giowin32.c b/glib/giowin32.c index 7d9c0c9..8c3592b 100644 --- a/glib/giowin32.c +++ b/glib/giowin32.c @@ -1297,9 +1297,9 @@ g_io_win32_fd_get_flags_internal (GIOChannel *channel, if (st->st_mode & _S_IFIFO) { channel->is_readable = - (PeekNamedPipe ((HANDLE) _get_osfhandle (win32_channel->fd), &c, 0, &count, NULL, NULL) == 0); + (PeekNamedPipe ((HANDLE) _get_osfhandle (win32_channel->fd), &c, 0, &count, NULL, NULL) != 0); channel->is_writeable = - (WriteFile ((HANDLE) _get_osfhandle (win32_channel->fd), &c, 0, &count, NULL) == 0); + (WriteFile ((HANDLE) _get_osfhandle (win32_channel->fd), &c, 0, &count, NULL) != 0); channel->is_seekable = FALSE; } else if (st->st_mode & _S_IFCHR) @@ -1311,19 +1311,20 @@ g_io_win32_fd_get_flags_internal (GIOChannel *channel, channel->is_readable = !!(st->st_mode & _S_IREAD); channel->is_writeable = - (WriteFile ((HANDLE) _get_osfhandle (win32_channel->fd), &c, 0, &count, NULL) == 0); + (WriteFile ((HANDLE) _get_osfhandle (win32_channel->fd), &c, 0, &count, NULL) != 0); - /* XXX What about devices that actually *are* seekable? But those would probably - * not be handled using the C runtime anyway, but using Windows-specific code. + /* XXX What about devices that actually *are* seekable? But + * those would probably not be handled using the C runtime + * anyway, but using Windows-specific code. */ channel->is_seekable = FALSE; } else { channel->is_readable = - (ReadFile ((HANDLE) _get_osfhandle (win32_channel->fd), &c, 0, &count, NULL) == 0); + (ReadFile ((HANDLE) _get_osfhandle (win32_channel->fd), &c, 0, &count, NULL) != 0); channel->is_writeable = - (WriteFile ((HANDLE) _get_osfhandle (win32_channel->fd), &c, 0, &count, NULL) == 0); + (WriteFile ((HANDLE) _get_osfhandle (win32_channel->fd), &c, 0, &count, NULL) != 0); channel->is_seekable = TRUE; } diff --git a/glib/gwin32.h b/glib/gwin32.h index 1fbcb25..5aca580 100644 --- a/glib/gwin32.h +++ b/glib/gwin32.h @@ -56,8 +56,8 @@ typedef int pid_t; * access: * unlink: or * open, read, write, lseek, close: - * rmdir: - * pipe: + * rmdir: + * pipe: */ /* pipe is not in OLDNAMES.LIB or -lmoldname-msvc. */