dovecot-2.2: lib-http: Fixed http_client_wait() assert.

dovecot at dovecot.org dovecot at dovecot.org
Tue Mar 5 11:45:44 EET 2013


details:   http://hg.dovecot.org/dovecot-2.2/rev/bdca6ecb5bb4
changeset: 15995:bdca6ecb5bb4
user:      Timo Sirainen <tss at iki.fi>
date:      Tue Mar 05 11:45:26 2013 +0200
description:
lib-http: Fixed http_client_wait() assert.

diffstat:

 src/lib-http/http-client.c |  5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diffs (15 lines):

diff -r 6daf58f568a0 -r bdca6ecb5bb4 src/lib-http/http-client.c
--- a/src/lib-http/http-client.c	Tue Mar 05 11:45:10 2013 +0200
+++ b/src/lib-http/http-client.c	Tue Mar 05 11:45:26 2013 +0200
@@ -160,7 +160,10 @@
 
 	client->ioloop = io_loop_create();
 	http_client_switch_ioloop(client);
-	i_assert(io_loop_have_ios(client->ioloop));
+	/* either we're waiting for network I/O or we're getting out of a
+	   callback using timeout_add_short(0) */
+	i_assert(io_loop_have_ios(client->ioloop) ||
+		 io_loop_have_immediate_timeouts(client->ioloop));
 
 	do {
 		http_client_debug(client,


More information about the dovecot-cvs mailing list