dovecot-1.3: Search result updating: Make sure search args are i...

dovecot at dovecot.org dovecot at dovecot.org
Thu Apr 16 03:25:06 EEST 2009


details:   http://hg.dovecot.org/dovecot-1.3/rev/755d3c958892
changeset: 9115:755d3c958892
user:      Timo Sirainen <tss at iki.fi>
date:      Wed Apr 15 20:20:56 2009 -0400
description:
Search result updating: Make sure search args are initialized.

diffstat:

1 file changed, 3 insertions(+)
src/lib-storage/index/index-search-result.c |    3 +++

diffs (20 lines):

diff -r 8b831d260dca -r 755d3c958892 src/lib-storage/index/index-search-result.c
--- a/src/lib-storage/index/index-search-result.c	Wed Apr 15 20:24:37 2009 -0400
+++ b/src/lib-storage/index/index-search-result.c	Wed Apr 15 20:20:56 2009 -0400
@@ -68,6 +68,8 @@ search_result_update_search(struct mail_
 	next_seq = search_seqs[0].seq1;
 	seqpos = 0;
 
+	mail_search_args_init(result->search_args, result->box, FALSE, NULL);
+
 	t = mailbox_transaction_begin(result->box, 0);
 	search_ctx = mailbox_search_init(t, result->search_args, NULL);
 	/* tell search that we're updating an existing search result,
@@ -99,6 +101,7 @@ search_result_update_search(struct mail_
 	}
 	mail_free(&mail);
 	ret = mailbox_search_deinit(&search_ctx);
+	mail_search_args_deinit(result->search_args);
 
 	if (next_seq != 0 && ret == 0) {
 		/* last message(s) didn't match. make sure they don't exist


More information about the dovecot-cvs mailing list