]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
lib-storage: Fix error handling if mailbox list index refresh fails
authorTimo Sirainen <timo.sirainen@dovecot.fi>
Tue, 4 Dec 2018 09:19:23 +0000 (11:19 +0200)
committerVille Savolainen <ville.savolainen@dovecot.fi>
Wed, 6 Feb 2019 08:09:33 +0000 (10:09 +0200)
The caller expects the error to be in mail_storage, not mailbox_list.

src/lib-storage/list/mailbox-list-index-status.c

index 1a6655b1dd03d1261dc2f7ba8555c0dbe1373744..ce88cf14acfb8f6ff610ec41e3a129a17cf24be3 100644 (file)
@@ -44,8 +44,10 @@ index_list_open_view(struct mailbox *box, bool status_check,
 
        if (MAILBOX_IS_NEVER_IN_INDEX(box) && status_check)
                return 0;
-       if (mailbox_list_index_refresh(box->list) < 0)
+       if (mailbox_list_index_refresh(box->list) < 0) {
+               mail_storage_copy_list_error(box->storage, box->list);
                return -1;
+       }
 
        node = mailbox_list_index_lookup(box->list, box->name);
        if (node == NULL) {