]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
dbox: Fixed setting mailbox GUID.
authorTimo Sirainen <tss@iki.fi>
Tue, 30 Jun 2009 01:53:16 +0000 (21:53 -0400)
committerTimo Sirainen <tss@iki.fi>
Tue, 30 Jun 2009 01:53:16 +0000 (21:53 -0400)
--HG--
branch : HEAD

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

index e43ebcbd0b088477b86653ae10093f4c97ad1e36..a4c08e7da862f782b035266a74419cf0dc751c33 100644 (file)
@@ -225,7 +225,7 @@ void dbox_update_header(struct dbox_mailbox *mbox,
        if (update != NULL && !mailbox_guid_is_empty(update->mailbox_guid)) {
                memcpy(new_hdr.mailbox_guid, update->mailbox_guid,
                       sizeof(new_hdr.mailbox_guid));
-       } else if (!mailbox_guid_is_empty(new_hdr.mailbox_guid)) {
+       } else if (mailbox_guid_is_empty(new_hdr.mailbox_guid)) {
                mail_generate_guid_128(new_hdr.mailbox_guid);
        }
 
@@ -382,7 +382,7 @@ static void dbox_storage_get_status_guid(struct mailbox *box,
        if (dbox_read_header(mbox, &hdr) < 0)
                memset(&hdr, 0, sizeof(hdr));
 
-       if (!mailbox_guid_is_empty(hdr.mailbox_guid)) {
+       if (mailbox_guid_is_empty(hdr.mailbox_guid)) {
                /* regenerate it */
                if (dbox_write_index_header(box, NULL) < 0 ||
                    dbox_read_header(mbox, &hdr) < 0)