dovecot-2.2: imap: Fixed crash at FETCH deinit caused by b638e19...

dovecot at dovecot.org dovecot at dovecot.org
Tue Nov 24 12:47:48 UTC 2015


details:   http://hg.dovecot.org/dovecot-2.2/rev/8d9b48c59490
changeset: 19413:8d9b48c59490
user:      Timo Sirainen <tss at iki.fi>
date:      Tue Nov 24 12:56:35 2015 +0200
description:
imap: Fixed crash at FETCH deinit caused by b638e19d3bd4
imap_fetch_free() would have been called twice, which caused problems.

diffstat:

 src/imap/cmd-fetch.c |  6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diffs (23 lines):

diff -r 26c565042d9d -r 8d9b48c59490 src/imap/cmd-fetch.c
--- a/src/imap/cmd-fetch.c	Tue Nov 24 11:50:15 2015 +0200
+++ b/src/imap/cmd-fetch.c	Tue Nov 24 12:56:35 2015 +0200
@@ -172,6 +172,11 @@
 	return TRUE;
 }
 
+static bool cmd_fetch_finished(struct client_command_context *cmd ATTR_UNUSED)
+{
+	return TRUE;
+}
+
 static bool cmd_fetch_finish(struct imap_fetch_context *ctx,
 			     struct client_command_context *cmd)
 {
@@ -199,6 +204,7 @@
 			   output bytes are included in it (which wouldn't
 			   happen if we called client_disconnect() here
 			   directly). */
+			cmd->func = cmd_fetch_finished;
 			return cmd->cancel;
 		}
 


More information about the dovecot-cvs mailing list