Mercurial > dovecot > original-hg > dovecot-1.2
comparison src/plugins/trash/trash-plugin.c @ 4848:967de900c73a HEAD
Mailbox list indexing and related changes. Currently works only with
maildir and mmap_disable=no. This allows doing STATUS to synced mailboxes
without opening their index files at all.
author | Timo Sirainen <tss@iki.fi> |
---|---|
date | Sun, 26 Nov 2006 00:17:39 +0200 |
parents | 49c9e7588de4 |
children | 6b0032df7008 |
comparison
equal
deleted
inserted
replaced
4847:7f250cd01843 | 4848:967de900c73a |
---|---|
40 | 40 |
41 static int sync_mailbox(struct mailbox *box) | 41 static int sync_mailbox(struct mailbox *box) |
42 { | 42 { |
43 struct mailbox_sync_context *ctx; | 43 struct mailbox_sync_context *ctx; |
44 struct mailbox_sync_rec sync_rec; | 44 struct mailbox_sync_rec sync_rec; |
45 struct mailbox_status status; | |
46 | 45 |
47 ctx = mailbox_sync_init(box, MAILBOX_SYNC_FLAG_FULL_READ); | 46 ctx = mailbox_sync_init(box, MAILBOX_SYNC_FLAG_FULL_READ); |
48 while (mailbox_sync_next(ctx, &sync_rec) > 0) | 47 while (mailbox_sync_next(ctx, &sync_rec) > 0) |
49 ; | 48 ; |
50 return mailbox_sync_deinit(&ctx, &status); | 49 return mailbox_sync_deinit(&ctx, 0, NULL); |
51 } | 50 } |
52 | 51 |
53 static int trash_clean_mailbox_open(struct trash_mailbox *trash) | 52 static int trash_clean_mailbox_open(struct trash_mailbox *trash) |
54 { | 53 { |
55 trash->box = mailbox_open(trash->storage, trash->name, NULL, | 54 trash->box = mailbox_open(trash->storage, trash->name, NULL, |