dovecot-1.2: IDLE: After a change, mailbox changes were being re...
dovecot at dovecot.org
dovecot at dovecot.org
Mon Mar 8 19:16:58 EET 2010
details: http://hg.dovecot.org/dovecot-1.2/rev/affad804356e
changeset: 9550:affad804356e
user: Timo Sirainen <tss at iki.fi>
date: Mon Mar 08 19:16:54 2010 +0200
description:
IDLE: After a change, mailbox changes were being re-checked every 0.5 seconds.
diffstat:
src/lib-storage/index/index-mailbox-check.c | 19 +++++++++----------
1 files changed, 9 insertions(+), 10 deletions(-)
diffs (36 lines):
diff -r 6794893d03c9 -r affad804356e src/lib-storage/index/index-mailbox-check.c
--- a/src/lib-storage/index/index-mailbox-check.c Mon Mar 08 19:07:06 2010 +0200
+++ b/src/lib-storage/index/index-mailbox-check.c Mon Mar 08 19:16:54 2010 +0200
@@ -23,6 +23,13 @@
struct io *io;
};
+static void notify_delay_callback(struct index_mailbox *ibox)
+{
+ if (ibox->notify_delay_to != NULL)
+ timeout_remove(&ibox->notify_delay_to);
+ ibox->box.notify_callback(&ibox->box, ibox->box.notify_context);
+}
+
static void check_timeout(struct index_mailbox *ibox)
{
struct index_notify_file *file;
@@ -37,16 +44,8 @@
}
}
- if (notify) {
- if (ibox->notify_delay_to != NULL)
- timeout_remove(&ibox->notify_delay_to);
- ibox->box.notify_callback(&ibox->box, ibox->box.notify_context);
- }
-}
-
-static void notify_delay_callback(struct index_mailbox *ibox)
-{
- ibox->box.notify_callback(&ibox->box, ibox->box.notify_context);
+ if (notify)
+ notify_delay_callback(ibox);
}
static void notify_callback(struct index_mailbox *ibox)
More information about the dovecot-cvs
mailing list