mirror of
https://git.notmuchmail.org/git/notmuch
synced 2024-11-25 04:18:08 +01:00
Unbreak the "notmuch setup" command.
The recent addition of support for automatically adding tags to new messages for "notmuch new" caused "notmuch setup" to segfault. The fix is simple, (just need to move a destroy function to inside a nearby if block). Did I mention recently we need to add a test suite?
This commit is contained in:
parent
ae0bd3f503
commit
16003e1f8f
1 changed files with 3 additions and 2 deletions
|
@ -264,9 +264,10 @@ add_files_recursive (notmuch_database_t *notmuch,
|
|||
/* success */
|
||||
case NOTMUCH_STATUS_SUCCESS:
|
||||
state->added_messages++;
|
||||
if (state->callback)
|
||||
if (state->callback) {
|
||||
(state->callback) (message);
|
||||
notmuch_message_destroy (message);
|
||||
notmuch_message_destroy (message);
|
||||
}
|
||||
break;
|
||||
/* Non-fatal issues (go on to next file) */
|
||||
case NOTMUCH_STATUS_DUPLICATE_MESSAGE_ID:
|
||||
|
|
Loading…
Reference in a new issue