[dovecot-cvs] dovecot/src/lib-storage/index/mbox mbox-storage.c, 1.100, 1.101 mbox-sync-parse.c, 1.28, 1.29 mbox-sync.c, 1.93, 1.94

cras at dovecot.org cras at dovecot.org
Sun Oct 3 19:33:01 EEST 2004


Update of /var/lib/cvs/dovecot/src/lib-storage/index/mbox
In directory talvi:/tmp/cvs-serv20915/lib-storage/index/mbox

Modified Files:
	mbox-storage.c mbox-sync-parse.c mbox-sync.c 
Log Message:
Index extensions can now specify record alignment, and it's possible to
resize header and records. Fixes mbox crashes with some 64bit systems.



Index: mbox-storage.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-storage/index/mbox/mbox-storage.c,v
retrieving revision 1.100
retrieving revision 1.101
diff -u -d -r1.100 -r1.101
--- mbox-storage.c	26 Sep 2004 14:15:56 -0000	1.100
+++ mbox-storage.c	3 Oct 2004 16:32:59 -0000	1.101
@@ -403,8 +403,9 @@
 	}
 
 	index = index_storage_alloc(index_dir, path, MBOX_INDEX_PREFIX);
-	mbox_ext_idx = mail_index_ext_register(index, "mbox",
-					       0, sizeof(uint64_t));
+	mbox_ext_idx = mail_index_ext_register(index, "mbox", 0,
+					       sizeof(uint64_t),
+					       sizeof(uint64_t));
 	ibox = index_storage_mailbox_init(storage, &mbox_mailbox,
 					  index, name, flags);
 	if (ibox == NULL)

Index: mbox-sync-parse.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-storage/index/mbox/mbox-sync-parse.c,v
retrieving revision 1.28
retrieving revision 1.29
diff -u -d -r1.28 -r1.29
--- mbox-sync-parse.c	26 Sep 2004 14:15:56 -0000	1.28
+++ mbox-sync-parse.c	3 Oct 2004 16:32:59 -0000	1.29
@@ -516,7 +516,7 @@
 	if (ibox->md5hdr_ext_idx == 0) {
 		ibox->md5hdr_ext_idx =
 			mail_index_ext_register(ibox->index, "header-md5",
-						0, 16);
+						0, 16, 1);
 	}
 
 	if (mail_index_lookup_ext(view, seq, ibox->md5hdr_ext_idx, &data) < 0) {

Index: mbox-sync.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-storage/index/mbox/mbox-sync.c,v
retrieving revision 1.93
retrieving revision 1.94
diff -u -d -r1.93 -r1.94
--- mbox-sync.c	26 Sep 2004 14:15:56 -0000	1.93
+++ mbox-sync.c	3 Oct 2004 16:32:59 -0000	1.94
@@ -815,7 +815,7 @@
 				sync_ctx->ibox->md5hdr_ext_idx =
 					mail_index_ext_register(
 						sync_ctx->ibox->index,
-						"header-md5", 0, 16);
+						"header-md5", 0, 16, 1);
 			}
 
 			if (mbox_sync_find_index_md5(sync_ctx,



More information about the dovecot-cvs mailing list