dovecot: If transaction log contains records with unknown types,...
dovecot at dovecot.org
dovecot at dovecot.org
Sat Nov 10 19:39:09 EET 2007
details: http://hg.dovecot.org/dovecot/rev/74f4cea90bcd
changeset: 6760:74f4cea90bcd
user: Timo Sirainen <tss at iki.fi>
date: Sat Nov 10 19:39:06 2007 +0200
description:
If transaction log contains records with unknown types, log an error instead
of assert-crashing.
diffstat:
1 file changed, 5 insertions(+), 1 deletion(-)
src/lib-index/mail-index-sync-update.c | 6 +++++-
diffs (16 lines):
diff -r 8e0d9821c0d7 -r 74f4cea90bcd src/lib-index/mail-index-sync-update.c
--- a/src/lib-index/mail-index-sync-update.c Sat Nov 10 19:18:51 2007 +0200
+++ b/src/lib-index/mail-index-sync-update.c Sat Nov 10 19:39:06 2007 +0200
@@ -594,7 +594,11 @@ int mail_index_sync_record(struct mail_i
break;
}
default:
- i_unreached();
+ mail_index_sync_set_corrupted(ctx,
+ "Unknown transaction record type 0x%x",
+ (hdr->type & MAIL_TRANSACTION_TYPE_MASK));
+ ret = -1;
+ break;
}
t_pop();
return ret;
More information about the dovecot-cvs
mailing list