[dovecot-cvs] dovecot/src/plugins/convert convert-storage.c, 1.5.2.9, 1.5.2.10
tss at dovecot.org
tss at dovecot.org
Thu Apr 12 20:09:30 EEST 2007
Update of /var/lib/cvs/dovecot/src/plugins/convert
In directory talvi:/tmp/cvs-serv6118
Modified Files:
Tag: branch_1_0
convert-storage.c
Log Message:
Don't create INBOX mailbox, so with maildir the maildirfolder file won't be
created there.
Index: convert-storage.c
===================================================================
RCS file: /var/lib/cvs/dovecot/src/plugins/convert/convert-storage.c,v
retrieving revision 1.5.2.9
retrieving revision 1.5.2.10
diff -u -d -r1.5.2.9 -r1.5.2.10
--- convert-storage.c 7 Apr 2007 08:07:49 -0000 1.5.2.9
+++ convert-storage.c 12 Apr 2007 17:09:28 -0000 1.5.2.10
@@ -163,13 +163,18 @@
return -1;
}
- /* Create and open the destination mailbox. */
+ /* Create and open the destination mailbox.
+ Except INBOX, it always exists. */
dest_name = mailbox_name_convert(dest_storage, source_storage, name);
- if (mail_storage_mailbox_create(dest_storage, dest_name, FALSE) < 0) {
- i_error("Mailbox conversion: Couldn't create mailbox %s: %s",
- dest_name, storage_error(dest_storage));
- mailbox_close(&srcbox);
- return -1;
+ if (strcmp(dest_name, "INBOX") != 0) {
+ if (mail_storage_mailbox_create(dest_storage, dest_name,
+ FALSE) < 0) {
+ i_error("Mailbox conversion: "
+ "Couldn't create mailbox %s: %s",
+ dest_name, storage_error(dest_storage));
+ mailbox_close(&srcbox);
+ return -1;
+ }
}
destbox = mailbox_open(dest_storage, dest_name, NULL,
More information about the dovecot-cvs
mailing list