changeset 22913:70289891b91a

po3pc: Handle unexpected server disconnections without assert-crash Fixes: Panic: file pop3c-client.c: line 308 (pop3c_client_wait_one): assertion failed: (client->fd != -1 || client->state == POP3C_CLIENT_STATE_CONNECTING)
author Timo Sirainen <timo.sirainen@dovecot.fi>
date Fri, 13 Apr 2018 13:33:56 +0300
parents 0ebd5557ce43
children 3edf73ffeb2e
files src/lib-storage/index/pop3c/pop3c-client.c
diffstat 1 files changed, 1 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/lib-storage/index/pop3c/pop3c-client.c	Tue Mar 13 16:36:44 2018 +0200
+++ b/src/lib-storage/index/pop3c/pop3c-client.c	Fri Apr 13 13:33:56 2018 +0300
@@ -302,6 +302,7 @@
 	    array_count(&client->commands) > 0) {
 		while (array_count(&client->commands) > 0)
 			pop3c_client_async_callback_disconnected(client);
+		return;
 	}
 
 	i_assert(client->fd != -1 ||