changeset 8056:f30268333748 HEAD

mbox: Fixed assert-crash with read-only mbox streams (e.g. zlib plugin)
author Timo Sirainen <tss@iki.fi>
date Thu, 24 Jul 2008 02:13:11 +0300
parents 1894a0b4957d
children 2fc09774bc02
files src/lib-storage/index/mbox/mbox-file.c
diffstat 1 files changed, 1 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/lib-storage/index/mbox/mbox-file.c	Thu Jul 24 02:04:08 2008 +0300
+++ b/src/lib-storage/index/mbox/mbox-file.c	Thu Jul 24 02:13:11 2008 +0300
@@ -125,6 +125,7 @@
 		if (mbox->mbox_fd == -1) {
 			/* read-only mbox stream */
 			i_assert(mbox->mbox_readonly);
+			i_stream_seek(mbox->mbox_file_stream, 0);
 		} else {
 			i_stream_destroy(&mbox->mbox_file_stream);
 		}