diff options
author | Eric Wong (Contractor, The Linux Foundation) <e@80x24.org> | 2018-02-08 03:32:05 +0000 |
---|---|---|
committer | Eric Wong (Contractor, The Linux Foundation) <e@80x24.org> | 2018-02-08 03:32:05 +0000 |
commit | da1189763600f25802d6054ac3414d799b9367d4 (patch) | |
tree | 6857df9aa88a0db1923414d6b0d726253c6c3e24 | |
parent | 8d0fac4089f0b8935fb29c99b8d0abce9b9449e6 (diff) | |
download | public-inbox-da1189763600f25802d6054ac3414d799b9367d4.tar.gz |
Hostnames can contain '-' and this allows public-inbox-watch(1) to work on machines which generate Maildir files with '-' in them.
-rw-r--r-- | lib/PublicInbox/WatchMaildir.pm | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/PublicInbox/WatchMaildir.pm b/lib/PublicInbox/WatchMaildir.pm index a3fab428..403b6cf9 100644 --- a/lib/PublicInbox/WatchMaildir.pm +++ b/lib/PublicInbox/WatchMaildir.pm @@ -170,7 +170,7 @@ sub _force_mid { sub _try_path { my ($self, $path) = @_; my @p = split(m!/+!, $path); - return if $p[-1] !~ /\A[a-zA-Z0-9][\w:,=\.]+\z/; + return if $p[-1] !~ /\A[a-zA-Z0-9][\-\w:,=\.]+\z/; if ($p[-1] =~ /:2,([A-Z]+)\z/i) { my $flags = $1; return if $flags =~ /[DT]/; # no [D]rafts or [T]rashed mail |