aboutsummaryrefslogtreecommitdiffstats
path: root/pullimap
diff options
context:
space:
mode:
authorGuilhem Moulin <guilhem@fripost.org>2016-03-12 22:14:39 +0100
committerGuilhem Moulin <guilhem@fripost.org>2016-03-12 22:40:58 +0100
commit85fd56f6f150dba0d74859a9d5e00f16d6b33955 (patch)
treef8a57fe4f81acfc8ad4a3f6a18d9c44be2267d4d /pullimap
parentc8376a4c8130f98a56fd65e370032c27234ed323 (diff)
Net::IMAP::InterIMAP, interimap: Add support for IMAP NOTIFY [RFC 5465].
Unsollicited LIST responses are currently ignored, hence interimap won't detect mailbox creation/deletion/subcription/unsubscription.
Diffstat (limited to 'pullimap')
-rwxr-xr-xpullimap3
1 files changed, 1 insertions, 2 deletions
diff --git a/pullimap b/pullimap
index 8eb2ac0..3eb2b52 100755
--- a/pullimap
+++ b/pullimap
@@ -346,7 +346,6 @@ unless (defined $CONFIG{idle}) {
$CONFIG{idle} = 1740 if defined $CONFIG{idle} and $CONFIG{idle} == 0; # 29 mins
while(1) {
- my $r = $IMAP->idle($CONFIG{idle}, sub() { $IMAP->has_new_mails($MAILBOX) });
- pull() if $r;
+ pull() if $IMAP->idle($CONFIG{idle}, \&Net::IMAP::InterIMAP::has_new_mails);
purge();
}