dovecot-2.0: lib-storage: Fixed mbox/cydir crashing on cache par...

dovecot at dovecot.org dovecot at dovecot.org
Fri Aug 6 17:12:12 EEST 2010


details:   http://hg.dovecot.org/dovecot-2.0/rev/4ef2280ee490
changeset: 11952:4ef2280ee490
user:      Timo Sirainen <tss at iki.fi>
date:      Fri Aug 06 15:11:06 2010 +0100
description:
lib-storage: Fixed mbox/cydir crashing on cache parsing deinit.

diffstat:

 src/lib-storage/index/index-mail.c |  5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

diffs (15 lines):

diff -r b38708f38e6c -r 4ef2280ee490 src/lib-storage/index/index-mail.c
--- a/src/lib-storage/index/index-mail.c	Fri Aug 06 15:10:52 2010 +0100
+++ b/src/lib-storage/index/index-mail.c	Fri Aug 06 15:11:06 2010 +0100
@@ -1405,6 +1405,11 @@
 		   don't bother trying to update cache file */
 		mail->data.no_caching = TRUE;
 		mail->data.forced_no_caching = TRUE;
+
+		if (mail->data.parser_ctx == NULL) {
+			/* we didn't even start cache parsing */
+			return;
+		}
 	}
 
 	/* This is needed with 0 byte mails to get hdr=NULL call done. */


More information about the dovecot-cvs mailing list