Mercurial > dovecot > core-2.2
changeset 19458:0b81127e53da
imap: Fixed assert-crash if client disconnected at a specific command state.
If there was a command with state=CLIENT_COMMAND_STATE_WAIT_SYNC and output
stream was already detected to be closed, we crashed with:
Panic: file imap-client.c: line 841 (client_check_command_hangs): assertion
failed: (!have_wait_unfinished || unfinished_count > 0)
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Fri, 04 Dec 2015 12:15:49 +0200 |
parents | a47d273e144f |
children | 6cb9889cc960 |
files | src/imap/imap-client.c |
diffstat | 1 files changed, 2 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/src/imap/imap-client.c Fri Dec 04 11:38:00 2015 +0200 +++ b/src/imap/imap-client.c Fri Dec 04 12:15:49 2015 +0200 @@ -880,7 +880,8 @@ if (!client_handle_input(client)) break; } - client_check_command_hangs(client); + if (!client->input->closed && !client->output->closed) + client_check_command_hangs(client); } /* Skip incoming data until newline is found,