提交 85152ca4 编写于 作者: R Richard Levitte

Use a simpler method to build a glob than splitpath and catpath

It turns out that the combination splitpath() could return an empty
string for the directory part.  This doesn't play well with catdir().
Reviewed-by: NRich Salz <rsalz@openssl.org>
上级 01a35a5d
......@@ -10,7 +10,7 @@
require 5.000;
use strict;
use File::Basename;
use File::Spec::Functions qw/:DEFAULT abs2rel rel2abs catpath splitpath/;
use File::Spec::Functions qw/:DEFAULT abs2rel rel2abs/;
use File::Path qw/make_path/;
use Cwd qw/:DEFAULT realpath/;
......@@ -175,8 +175,7 @@ die "erroneous version information in opensslv.h: ",
# Collect target configurations
my ($vol, $dir, $dummy) = splitpath($0);
my $pattern = catpath($vol, catdir($dir, "Configurations"), "*.conf");
my $pattern = catfile(dirname($0), "Configurations", "*.conf");
foreach (sort glob($pattern) ) {
&read_config($_);
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册