Mercurial > dovecot > original-hg > dovecot-1.2
comparison src/plugins/mbox-snarf/mbox-snarf-plugin.c @ 8468:d4eab639c253 HEAD
mailbox_open() now takes struct mail_storage ** so it can be changed.
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Fri, 21 Nov 2008 19:24:04 +0200 |
parents | d3cbd3494a8c |
children | e8a8383895df |
comparison
equal
deleted
inserted
replaced
8467:03c418eadc8b | 8468:d4eab639c253 |
---|---|
98 static struct mailbox_sync_context * | 98 static struct mailbox_sync_context * |
99 mbox_snarf_sync_init(struct mailbox *box, enum mailbox_sync_flags flags) | 99 mbox_snarf_sync_init(struct mailbox *box, enum mailbox_sync_flags flags) |
100 { | 100 { |
101 struct mbox_snarf_mail_storage *mstorage = | 101 struct mbox_snarf_mail_storage *mstorage = |
102 MBOX_SNARF_CONTEXT(box->storage); | 102 MBOX_SNARF_CONTEXT(box->storage); |
103 struct mail_storage *storage; | |
103 struct mbox_snarf_mailbox *mbox = MBOX_SNARF_CONTEXT(box); | 104 struct mbox_snarf_mailbox *mbox = MBOX_SNARF_CONTEXT(box); |
104 | 105 |
105 if (mbox->spool_mbox == NULL) { | 106 if (mbox->spool_mbox == NULL) { |
106 /* try to open the spool mbox */ | 107 /* try to open the spool mbox */ |
107 mstorage->open_spool_inbox = TRUE; | 108 mstorage->open_spool_inbox = TRUE; |
109 storage = box->storage; | |
108 mbox->spool_mbox = | 110 mbox->spool_mbox = |
109 mailbox_open(box->storage, "INBOX", NULL, | 111 mailbox_open(&storage, "INBOX", NULL, |
110 MAILBOX_OPEN_KEEP_RECENT | | 112 MAILBOX_OPEN_KEEP_RECENT | |
111 MAILBOX_OPEN_NO_INDEX_FILES); | 113 MAILBOX_OPEN_NO_INDEX_FILES); |
112 mstorage->open_spool_inbox = FALSE; | 114 mstorage->open_spool_inbox = FALSE; |
113 } | 115 } |
114 | 116 |