From 1c653e36351403c65ef3babd1ad5e19546cdd2af Mon Sep 17 00:00:00 2001 From: Tor Lillqvist Date: Fri, 15 Mar 2002 23:34:53 +0000 Subject: [PATCH] glib/giowin32.c (g_io_win32_dispatch): Check buffer condition here, too. 2002-03-16 Tor Lillqvist glib/giowin32.c (g_io_win32_dispatch): Check buffer condition here, too. --- ChangeLog | 5 +++-- ChangeLog.pre-2-10 | 5 +++-- ChangeLog.pre-2-12 | 5 +++-- ChangeLog.pre-2-2 | 5 +++-- ChangeLog.pre-2-4 | 5 +++-- ChangeLog.pre-2-6 | 5 +++-- ChangeLog.pre-2-8 | 5 +++-- glib/giowin32.c | 3 ++- 8 files changed, 23 insertions(+), 15 deletions(-) diff --git a/ChangeLog b/ChangeLog index 268fa9f2a..338603059 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,11 +1,12 @@ 2002-03-16 Tor Lillqvist * glib/giowin32.c: Some debugging output formatting changes. The - following two changes fixes a problem with buffered GIOChannels, - noticed with the help of Owen's test program, thanks! + following changes fix a problem with buffered GIOChannels, noticed + with the help of Owen's test program, thanks! (#59969) (g_io_win32_prepare): Return value that takes the buffer condition into account, like g_io_unix_prepare() does. (g_io_win32_check): Ditto, like g_io_unix_check(). + (g_io_win32_dispatch): Ditto, like g_io_unix_dispatch(). Thu Mar 14 17:37:45 2002 Owen Taylor diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index 268fa9f2a..338603059 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -1,11 +1,12 @@ 2002-03-16 Tor Lillqvist * glib/giowin32.c: Some debugging output formatting changes. The - following two changes fixes a problem with buffered GIOChannels, - noticed with the help of Owen's test program, thanks! + following changes fix a problem with buffered GIOChannels, noticed + with the help of Owen's test program, thanks! (#59969) (g_io_win32_prepare): Return value that takes the buffer condition into account, like g_io_unix_prepare() does. (g_io_win32_check): Ditto, like g_io_unix_check(). + (g_io_win32_dispatch): Ditto, like g_io_unix_dispatch(). Thu Mar 14 17:37:45 2002 Owen Taylor diff --git a/ChangeLog.pre-2-12 b/ChangeLog.pre-2-12 index 268fa9f2a..338603059 100644 --- a/ChangeLog.pre-2-12 +++ b/ChangeLog.pre-2-12 @@ -1,11 +1,12 @@ 2002-03-16 Tor Lillqvist * glib/giowin32.c: Some debugging output formatting changes. The - following two changes fixes a problem with buffered GIOChannels, - noticed with the help of Owen's test program, thanks! + following changes fix a problem with buffered GIOChannels, noticed + with the help of Owen's test program, thanks! (#59969) (g_io_win32_prepare): Return value that takes the buffer condition into account, like g_io_unix_prepare() does. (g_io_win32_check): Ditto, like g_io_unix_check(). + (g_io_win32_dispatch): Ditto, like g_io_unix_dispatch(). Thu Mar 14 17:37:45 2002 Owen Taylor diff --git a/ChangeLog.pre-2-2 b/ChangeLog.pre-2-2 index 268fa9f2a..338603059 100644 --- a/ChangeLog.pre-2-2 +++ b/ChangeLog.pre-2-2 @@ -1,11 +1,12 @@ 2002-03-16 Tor Lillqvist * glib/giowin32.c: Some debugging output formatting changes. The - following two changes fixes a problem with buffered GIOChannels, - noticed with the help of Owen's test program, thanks! + following changes fix a problem with buffered GIOChannels, noticed + with the help of Owen's test program, thanks! (#59969) (g_io_win32_prepare): Return value that takes the buffer condition into account, like g_io_unix_prepare() does. (g_io_win32_check): Ditto, like g_io_unix_check(). + (g_io_win32_dispatch): Ditto, like g_io_unix_dispatch(). Thu Mar 14 17:37:45 2002 Owen Taylor diff --git a/ChangeLog.pre-2-4 b/ChangeLog.pre-2-4 index 268fa9f2a..338603059 100644 --- a/ChangeLog.pre-2-4 +++ b/ChangeLog.pre-2-4 @@ -1,11 +1,12 @@ 2002-03-16 Tor Lillqvist * glib/giowin32.c: Some debugging output formatting changes. The - following two changes fixes a problem with buffered GIOChannels, - noticed with the help of Owen's test program, thanks! + following changes fix a problem with buffered GIOChannels, noticed + with the help of Owen's test program, thanks! (#59969) (g_io_win32_prepare): Return value that takes the buffer condition into account, like g_io_unix_prepare() does. (g_io_win32_check): Ditto, like g_io_unix_check(). + (g_io_win32_dispatch): Ditto, like g_io_unix_dispatch(). Thu Mar 14 17:37:45 2002 Owen Taylor diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6 index 268fa9f2a..338603059 100644 --- a/ChangeLog.pre-2-6 +++ b/ChangeLog.pre-2-6 @@ -1,11 +1,12 @@ 2002-03-16 Tor Lillqvist * glib/giowin32.c: Some debugging output formatting changes. The - following two changes fixes a problem with buffered GIOChannels, - noticed with the help of Owen's test program, thanks! + following changes fix a problem with buffered GIOChannels, noticed + with the help of Owen's test program, thanks! (#59969) (g_io_win32_prepare): Return value that takes the buffer condition into account, like g_io_unix_prepare() does. (g_io_win32_check): Ditto, like g_io_unix_check(). + (g_io_win32_dispatch): Ditto, like g_io_unix_dispatch(). Thu Mar 14 17:37:45 2002 Owen Taylor diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8 index 268fa9f2a..338603059 100644 --- a/ChangeLog.pre-2-8 +++ b/ChangeLog.pre-2-8 @@ -1,11 +1,12 @@ 2002-03-16 Tor Lillqvist * glib/giowin32.c: Some debugging output formatting changes. The - following two changes fixes a problem with buffered GIOChannels, - noticed with the help of Owen's test program, thanks! + following changes fix a problem with buffered GIOChannels, noticed + with the help of Owen's test program, thanks! (#59969) (g_io_win32_prepare): Return value that takes the buffer condition into account, like g_io_unix_prepare() does. (g_io_win32_check): Ditto, like g_io_unix_check(). + (g_io_win32_dispatch): Ditto, like g_io_unix_dispatch(). Thu Mar 14 17:37:45 2002 Owen Taylor diff --git a/glib/giowin32.c b/glib/giowin32.c index 513ace95c..896e8bce5 100644 --- a/glib/giowin32.c +++ b/glib/giowin32.c @@ -619,6 +619,7 @@ g_io_win32_dispatch (GSource *source, { GIOFunc func = (GIOFunc)callback; GIOWin32Watch *watch = (GIOWin32Watch *)source; + GIOCondition buffer_condition = g_io_channel_get_buffer_condition (watch->channel); if (!func) { @@ -628,7 +629,7 @@ g_io_win32_dispatch (GSource *source, } return (*func) (watch->channel, - watch->pollfd.revents & watch->condition, + (watch->pollfd.revents | buffer_condition) & watch->condition, user_data); }