# HG changeset patch # User Timo Sirainen # Date 1497376823 -10800 # Node ID 9c8e13eb813cd7a08f9d74a0ad5e4fe05d50bfce # Parent c836d071d8a7e2dacc5ae4d1edc8236274b69fd2 dsync: Fix panic if syncing fails during attribute iteration Fixes: Panic: file dict.c: line 104 (dict_deinit): assertion failed: (dict->iter_count == 0) diff -r c836d071d8a7 -r 9c8e13eb813c src/doveadm/dsync/dsync-mailbox-export.c --- a/src/doveadm/dsync/dsync-mailbox-export.c Fri Aug 25 18:02:44 2017 +0300 +++ b/src/doveadm/dsync/dsync-mailbox-export.c Tue Jun 13 21:00:23 2017 +0300 @@ -928,6 +928,8 @@ *_exporter = NULL; + if (exporter->attr_iter != NULL) + (void)mailbox_attribute_iter_deinit(&exporter->attr_iter); dsync_mailbox_export_body_search_deinit(exporter); (void)mailbox_transaction_commit(&exporter->trans); if (exporter->wanted_headers != NULL)