2008-09-20 [colin] 3.5.0cvs116

* src/etpan/etpan-thread-manager.c
	* src/etpan/imap-thread.c
	* src/etpan/nntp-thread.c
		Windows: Fix hang on IMAP/NNTP
This commit is contained in:
Colin Leroy 2008-09-20 08:15:55 +00:00
parent 87768b9d7c
commit 3afda3dfe2
6 changed files with 35 additions and 3 deletions

View file

@ -1,3 +1,10 @@
2008-09-20 [colin] 3.5.0cvs116
* src/etpan/etpan-thread-manager.c
* src/etpan/imap-thread.c
* src/etpan/nntp-thread.c
Windows: Fix hang on IMAP/NNTP
2008-09-20 [colin] 3.5.0cvs115
* src/common/utils.c

View file

@ -3527,3 +3527,4 @@
( cvs diff -u -r 1.94.2.186 -r 1.94.2.187 src/messageview.c; cvs diff -u -r 1.49.2.115 -r 1.49.2.116 src/procmime.c; cvs diff -u -r 1.96.2.206 -r 1.96.2.207 src/textview.c; cvs diff -u -r 1.1.4.32 -r 1.1.4.33 src/gtk/logwindow.c; cvs diff -u -r 1.1.4.15 -r 1.1.4.16 src/gtk/logwindow.h; ) > 3.5.0cvs113.patchset
( cvs diff -u -r 1.49.2.116 -r 1.49.2.117 src/procmime.c; cvs diff -u -r 1.96.2.207 -r 1.96.2.208 src/textview.c; ) > 3.5.0cvs114.patchset
( cvs diff -u -r 1.36.2.146 -r 1.36.2.147 src/common/utils.c; ) > 3.5.0cvs115.patchset
( cvs diff -u -r 1.1.4.10 -r 1.1.4.11 src/etpan/etpan-thread-manager.c; cvs diff -u -r 1.1.4.104 -r 1.1.4.105 src/etpan/imap-thread.c; cvs diff -u -r 1.1.2.8 -r 1.1.2.9 src/etpan/nntp-thread.c; ) > 3.5.0cvs116.patchset

View file

@ -11,7 +11,7 @@ MINOR_VERSION=5
MICRO_VERSION=0
INTERFACE_AGE=0
BINARY_AGE=0
EXTRA_VERSION=115
EXTRA_VERSION=116
EXTRA_RELEASE=
EXTRA_GTK2_VERSION=

View file

@ -283,10 +283,13 @@ static void manager_notify(struct etpan_thread_manager * manager)
static void manager_ack(struct etpan_thread_manager * manager)
{
#ifndef G_OS_WIN32
char ch;
ssize_t r;
r = read(manager->notify_fds[0], &ch, 1);
#else
/* done in the GIOChannel handler in imap-thread.c and nntp-thread.c */
#endif
}
static void thread_lock(struct etpan_thread * thread)

View file

@ -81,6 +81,13 @@ static gboolean thread_manager_event(GIOChannel * source,
GIOCondition condition,
gpointer data)
{
#ifdef G_OS_WIN32
gsize bytes_read;
gchar ch;
if (condition & G_IO_IN)
g_io_channel_read_chars(source, &ch, 1, &bytes_read, NULL);
#endif
etpan_thread_manager_loop(thread_manager);
return TRUE;
@ -272,8 +279,11 @@ void imap_main_init(gboolean skip_ssl_cert_check)
fd_thread_manager = etpan_thread_manager_get_fd(thread_manager);
#ifndef G_OS_WIN32
io_channel = g_io_channel_unix_new(fd_thread_manager);
#else
io_channel = g_io_channel_win32_new_fd(fd_thread_manager);
#endif
thread_manager_signal = g_io_add_watch_full(io_channel, 0, G_IO_IN,
thread_manager_event,
(gpointer) NULL,

View file

@ -116,6 +116,13 @@ static gboolean thread_manager_event(GIOChannel * source,
GIOCondition condition,
gpointer data)
{
#ifdef G_OS_WIN32
gsize bytes_read;
gchar ch;
if (condition & G_IO_IN)
g_io_channel_read_chars(source, &ch, 1, &bytes_read, NULL);
#endif
etpan_thread_manager_loop(thread_manager);
return TRUE;
@ -137,7 +144,11 @@ void nntp_main_init(gboolean skip_ssl_cert_check)
fd_thread_manager = etpan_thread_manager_get_fd(thread_manager);
#ifndef G_OS_WIN32
io_channel = g_io_channel_unix_new(fd_thread_manager);
#else
io_channel = g_io_channel_win32_new_fd(fd_thread_manager);
#endif
thread_manager_signal = g_io_add_watch_full(io_channel, 0, G_IO_IN,
thread_manager_event,