From 6fec66eb87027aa308e1b8b30b2e3ad50275593b Mon Sep 17 00:00:00 2001 From: "Andrew V. Samoilov" Date: Tue, 24 Dec 2002 06:56:16 +0000 Subject: [PATCH] * extfs/mailfs.in: Quote filename when openning mailbox. --- vfs/ChangeLog | 4 ++++ vfs/extfs/mailfs.in | 7 ++++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/vfs/ChangeLog b/vfs/ChangeLog index 15d71e631..584fbe804 100644 --- a/vfs/ChangeLog +++ b/vfs/ChangeLog @@ -1,3 +1,7 @@ +2002-12-24 Andrew V. Samoilov + + * extfs/mailfs.in: Quote filename when openning mailbox. + 2002-12-24 Adam Byrtek * extfs/apt.in, extfs/dpkg.in: Avoid stat on non-existing file. diff --git a/vfs/extfs/mailfs.in b/vfs/extfs/mailfs.in index 220ae05e6..d5b290181 100644 --- a/vfs/extfs/mailfs.in +++ b/vfs/extfs/mailfs.in @@ -125,12 +125,13 @@ exit 1 unless ($#ARGV >= 1); $msg_nr=0; $cmd=shift; $mbox_name=shift; -$_=`$file $mbox_name`; +my $mbox_qname = quotemeta ($mbox_name); +$_=`$file $mbox_qname`; if (/gzip/) { - exit 1 unless (open IN, "$zcat $mbox_name|"); + exit 1 unless (open IN, "$zcat $mbox_qname|"); } elsif (/bzip/) { - exit 1 unless (open IN, "$bzcat $mbox_name|"); + exit 1 unless (open IN, "$bzcat $mbox_qname|"); } else { exit 1 unless (open IN, "<$mbox_name"); }