Mercurial > dovecot > core-2.2
changeset 22900:cfadc7f52953
notify: Fix crash if NO_NOTIFY transaction is rolled back during commit
Fixes: Panic: no notify_mail_txn found
author | Timo Sirainen <timo.sirainen@dovecot.fi> |
---|---|
date | Wed, 07 Mar 2018 11:24:30 +0200 |
parents | 093ef44c44e6 |
children | 6bd037753856 |
files | src/plugins/notify/notify-storage.c |
diffstat | 1 files changed, 2 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/src/plugins/notify/notify-storage.c Thu Mar 15 13:19:53 2018 +0200 +++ b/src/plugins/notify/notify-storage.c Wed Mar 07 11:24:30 2018 +0200 @@ -145,7 +145,8 @@ bool no_notify = (t->flags & MAILBOX_TRANSACTION_FLAG_NO_NOTIFY) != 0; if ((lbox->super.transaction_commit(t, changes_r)) < 0) { - notify_contexts_mail_transaction_rollback(t); + if (!no_notify) + notify_contexts_mail_transaction_rollback(t); return -1; }