summaryrefslogtreecommitdiff
path: root/lib/Apache/Config/Preproc
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org.ua>2018-02-20 15:15:30 +0200
committerSergey Poznyakoff <gray@gnu.org.ua>2018-02-20 15:15:30 +0200
commit2c494255a3bf9ac3fda8c5d85e840d6b9c902d00 (patch)
treed6b03cfa4eb5cdb1c4cbdb1c8caf5944b1ab1093 /lib/Apache/Config/Preproc
parentad5361f9a7992302e9a1821fa36bbd5f60df15ec (diff)
downloadacpp-2c494255a3bf9ac3fda8c5d85e840d6b9c902d00.tar.gz
acpp-2c494255a3bf9ac3fda8c5d85e840d6b9c902d00.tar.bz2
Correctly handle includes referring to a directory
Previous versions were unable to expand statements like Include /some/dir where /some/dir is the name of an existing directory. This commit fixes that. * lib/Apache/Config/Preproc/include.pm (expand): Append '/*' if pattern is an existing directory.
Diffstat (limited to 'lib/Apache/Config/Preproc')
-rw-r--r--lib/Apache/Config/Preproc/include.pm1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/Apache/Config/Preproc/include.pm b/lib/Apache/Config/Preproc/include.pm
index 7b3eebe..b4fd7b1 100644
--- a/lib/Apache/Config/Preproc/include.pm
+++ b/lib/Apache/Config/Preproc/include.pm
@@ -73,6 +73,7 @@ sub expand {
}
}
+ $pat = File::Spec->catfile($pat, '*') if -d $pat;
my @filelist = glob $pat;
if (@filelist) {
foreach my $file (@filelist) {

Return to:

Send suggestions and report system problems to the System administrator.