]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
dbox: mail_temp_scan_interval - Fix deleted temp file prefix
authorTimo Sirainen <timo.sirainen@open-xchange.com>
Tue, 20 Jun 2023 19:28:35 +0000 (22:28 +0300)
committerMarkus Valentin <markus.valentin@open-xchange.com>
Wed, 28 Jun 2023 12:25:38 +0000 (14:25 +0200)
dbox files are always created with DBOX_TEMP_FILE_PREFIX, not the mailbox
list-specific prefix. This was a problem only if dbox was used with
LAYOUT=Maildir++, which nobody was likely to do. Other layouts had
identical temp file prefixes to DBOX_TEMP_FILE_PREFIX.

src/lib-storage/index/dbox-common/dbox-storage.c

index 35ab65cc5c468dd5f162a6d58083c4e1bac48865..b006412f59b4a1ed2589240a9b3fecbb19a80950 100644 (file)
@@ -223,8 +223,8 @@ dbox_cleanup_temp_files(struct mailbox_list *list, const char *path,
                return stated;
        }
 
-       const char *prefix = mailbox_list_get_global_temp_prefix(list);
-       (void)unlink_old_files(path, prefix, ioloop_time - DBOX_TMP_DELETE_SECS);
+       (void)unlink_old_files(path, DBOX_TEMP_FILE_PREFIX,
+                              ioloop_time - DBOX_TMP_DELETE_SECS);
        return TRUE;
 }