From 2be6268e01a368817b27cdbbee7b2641ec1653c6 Mon Sep 17 00:00:00 2001 From: Guilhem Moulin Date: Fri, 10 May 2019 01:03:50 +0200 Subject: libinterimap: bugfix: fix escaped hierarchy delimiters in LIST reponses. The were returned as escaped quoted specials, like "\\", not as a single character (backslash in this case). --- Changelog | 8 ++++++++ interimap | 4 ++-- lib/Net/IMAP/InterIMAP.pm | 4 ++-- pullimap | 2 +- 4 files changed, 13 insertions(+), 5 deletions(-) diff --git a/Changelog b/Changelog index 5a9074a..17f4661 100644 --- a/Changelog +++ b/Changelog @@ -1,3 +1,11 @@ +interimap (0.5) upstream; + + - libinterimap: bugfix: hierarchy delimiters in LIST responses were + returned as an escaped quoted special, like "\\", not as a single + character (backslash in this case). + + -- Guilhem Moulin Fri, 10 May 2019 00:58:14 +0200 + interimap (0.4) upstream; * pullimap: replace non RFC 5321-compliant envelope sender addresses diff --git a/interimap b/interimap index 5b1bc63..bb7013d 100755 --- a/interimap +++ b/interimap @@ -22,7 +22,7 @@ use v5.14.2; use strict; use warnings; -our $VERSION = '0.4'; +our $VERSION = '0.5'; my $NAME = 'interimap'; use Getopt::Long qw/:config posix_default no_ignore_case gnu_compat bundling auto_version/; @@ -32,7 +32,7 @@ use Fcntl qw/F_GETFD F_SETFD FD_CLOEXEC/; use List::Util 'first'; use lib 'lib'; -use Net::IMAP::InterIMAP 0.0.4 qw/xdg_basedir read_config compact_set/; +use Net::IMAP::InterIMAP 0.0.5 qw/xdg_basedir read_config compact_set/; # Clean up PATH $ENV{PATH} = join ':', qw{/usr/bin /bin}; diff --git a/lib/Net/IMAP/InterIMAP.pm b/lib/Net/IMAP/InterIMAP.pm index a773f08..37616f4 100644 --- a/lib/Net/IMAP/InterIMAP.pm +++ b/lib/Net/IMAP/InterIMAP.pm @@ -16,7 +16,7 @@ # along with this program. If not, see . #---------------------------------------------------------------------- -package Net::IMAP::InterIMAP v0.0.4; +package Net::IMAP::InterIMAP v0.0.5; use warnings; use strict; @@ -2368,7 +2368,7 @@ sub _resp($$;&$$) { $self->panic($_) unless $_ eq ''; $mailbox = 'INBOX' if uc $mailbox eq 'INBOX'; # INBOX is case-insensitive undef $delim if uc $delim eq 'NIL'; - $delim =~ s/\A"(.*)"\z/$1/ if defined $delim; + $self->panic($_) if defined $delim and $delim !~ s/\A"\\?(.)"\z/$1/; $self->_update_cache_for($mailbox, DELIMITER => $delim); $self->_update_cache_for($mailbox, LIST_ATTRIBUTES => \@attrs); $callback->($mailbox, $delim, @attrs) if defined $callback and $cmd eq 'LIST'; diff --git a/pullimap b/pullimap index 495b99e..84587fe 100755 --- a/pullimap +++ b/pullimap @@ -32,7 +32,7 @@ use List::Util 'first'; use Socket qw/PF_INET PF_INET6 SOCK_STREAM/; use lib 'lib'; -use Net::IMAP::InterIMAP 0.0.4 qw/xdg_basedir read_config compact_set/; +use Net::IMAP::InterIMAP 0.0.5 qw/xdg_basedir read_config compact_set/; # Clean up PATH $ENV{PATH} = join ':', qw{/usr/bin /bin}; -- cgit v1.2.3