# HG changeset patch # User Timo Sirainen # Date 1287070294 -3600 # Node ID 1b40e217e02061dd0e2fcdf99779dca5b60f1156 # Parent 0149beb01eec7fb0fe3856e38db9bc4616023ff1 lib-storage: Fixed mbox/cydir crashing on failed cache parsing deinit. diff -r 0149beb01eec -r 1b40e217e020 src/lib-storage/index/index-mail.c --- a/src/lib-storage/index/index-mail.c Fri Oct 01 22:10:05 2010 +0100 +++ b/src/lib-storage/index/index-mail.c Thu Oct 14 16:31:34 2010 +0100 @@ -1402,6 +1402,11 @@ /* we're going to delete this mail anyway, don't bother trying to update cache file */ mail->data.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. */