diff src/doveadm/dsync/dsync-brain.c @ 17377:a21ac1261487

dsync: mailbox_metadata.cache_fields must be copied to permanent memory. Any other call to mailbox_get_metadata() would have cleared the memory.
author Timo Sirainen <tss@iki.fi>
date Mon, 12 May 2014 12:51:50 +0300
parents 9669c9a8984f
children eff79a80e0c9
line wrap: on
line diff
--- a/src/doveadm/dsync/dsync-brain.c	Mon May 12 12:18:46 2014 +0300
+++ b/src/doveadm/dsync/dsync-brain.c	Mon May 12 12:51:50 2014 +0300
@@ -299,6 +299,9 @@
 		hash_table_iterate_deinit(&brain->mailbox_states_iter);
 	hash_table_destroy(&brain->mailbox_states);
 
+	if (brain->dsync_box_pool != NULL)
+		pool_unref(&brain->dsync_box_pool);
+
 	if (brain->lock_fd != -1) {
 		/* unlink the lock file before it gets unlocked */
 		if (unlink(brain->lock_path) < 0)