aboutsummaryrefslogtreecommitdiffstats
path: root/interimap
diff options
context:
space:
mode:
authorGuilhem Moulin <guilhem@fripost.org>2019-11-08 06:53:19 +0100
committerGuilhem Moulin <guilhem@fripost.org>2019-11-08 22:07:26 +0100
commitd08ee23dccf56af292a9616986e58cc39386e3fb (patch)
tree6e552f66230050a09b4c63c352f10c18b3568561 /interimap
parent37ebe331178e2b7d225a31f64463aef5448d4970 (diff)
Remove deprecated/buggy 'o' regexp modifier.
Diffstat (limited to 'interimap')
-rwxr-xr-xinterimap7
1 files changed, 5 insertions, 2 deletions
diff --git a/interimap b/interimap
index 87c3a64..f170ded 100755
--- a/interimap
+++ b/interimap
@@ -636,6 +636,10 @@ sub sync_mailbox_list() {
state $sth_subscribe = $DBH->prepare(q{
UPDATE mailboxes SET subscribed = ? WHERE idx = ?
});
+ state $ignore_mailbox = do {
+ my $re = $CONF->{_}->{"ignore-mailbox"};
+ defined $re ? qr/$re/ : undef
+ };
foreach my $name (qw/local remote/) {
foreach my $mbx (keys %{$IMAP->{$name}->{mailboxes}}) {
@@ -645,8 +649,7 @@ sub sync_mailbox_list() {
# exclude ignored mailboxes (taken from the default config as it doesn't
# make sense to ignore mailboxes from one side but not the other
- next if !@ARGV and defined $CONF->{_}->{"ignore-mailbox"}
- and $mbx =~ /$CONF->{_}->{"ignore-mailbox"}/o;
+ next if !@ARGV and defined $ignore_mailbox and $mbx =~ $ignore_mailbox;
$mailboxes{$mbx} = 1;
}
}