dovecot-2.2: lib-http: Avoid crashes on failing http_client_requ...
dovecot at dovecot.org
dovecot at dovecot.org
Mon Sep 21 21:56:34 UTC 2015
details: http://hg.dovecot.org/dovecot-2.2/rev/052d8d7654f6
changeset: 19175:052d8d7654f6
user: Timo Sirainen <tss at iki.fi>
date: Tue Sep 22 00:55:15 2015 +0300
description:
lib-http: Avoid crashes on failing http_client_request_send_payload() calls
It HTTP server connection died, ioloop might not have anything to do
anymore:
Panic: file ioloop-epoll.c: line 187 (io_loop_handler_run_internal): assertion failed: (msecs >= 0)
diffstat:
src/lib-http/http-client-request.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diffs (21 lines):
diff -r fa306ce6c02a -r 052d8d7654f6 src/lib-http/http-client-request.c
--- a/src/lib-http/http-client-request.c Tue Sep 22 00:40:14 2015 +0300
+++ b/src/lib-http/http-client-request.c Tue Sep 22 00:55:15 2015 +0300
@@ -981,6 +981,8 @@
if (!sending && req->payload_input != NULL)
i_stream_unref(&req->payload_input);
}
+ if (req->client->ioloop != NULL)
+ io_loop_stop(req->client->ioloop);
}
void http_client_request_error_delayed(struct http_client_request **_req)
@@ -1039,6 +1041,8 @@
if (req->queue != NULL)
http_client_queue_drop_request(req->queue, req);
+ if (req->client->ioloop != NULL)
+ io_loop_stop(req->client->ioloop);
http_client_request_unref(_req);
}
More information about the dovecot-cvs
mailing list