[dovecot-cvs] dovecot/src/lib-index mail-index-sync.c,1.49,1.50

cras at dovecot.org cras at dovecot.org
Wed Feb 9 01:02:45 EET 2005


Update of /var/lib/cvs/dovecot/src/lib-index
In directory talvi:/tmp/cvs-serv4770

Modified Files:
	mail-index-sync.c 
Log Message:
Keyword reset crashfix



Index: mail-index-sync.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/lib-index/mail-index-sync.c,v
retrieving revision 1.49
retrieving revision 1.50
diff -u -d -r1.49 -r1.50
--- mail-index-sync.c	8 Feb 2005 12:28:12 -0000	1.49
+++ mail-index-sync.c	8 Feb 2005 23:02:42 -0000	1.50
@@ -80,14 +80,17 @@
 {
 	const struct mail_transaction_keyword_reset *u = ctx->data;
 	size_t i, size = ctx->hdr->size / sizeof(*u);
+	struct mail_keywords *keywords;
 	uint32_t uid;
 
+	keywords = mail_index_keywords_create(ctx->trans, NULL);
 	for (i = 0; i < size; i++) {
 		for (uid = u[i].uid1; uid <= u[i].uid2; uid++) {
 			mail_index_update_keywords(ctx->trans, uid,
-						   MODIFY_REPLACE, NULL);
+						   MODIFY_REPLACE, keywords);
 		}
 	}
+	mail_index_keywords_free(keywords);
 }
 
 static void mail_index_sync_add_append(struct mail_index_sync_ctx *ctx)



More information about the dovecot-cvs mailing list