diff options
author | Martijn Koster <mak@excitecorp.com> | 1998-10-21 14:12:03 +0100 |
---|---|---|
committer | Gurusamy Sarathy <gsar@cpan.org> | 1998-10-25 06:59:03 +0000 |
commit | dbc63d465574018de759a7737c0926b69e546aa6 (patch) | |
tree | c337930f0bc616ea4b7116dd63fabd9eff812125 /lib | |
parent | e49da4e70c0834d74fe2e994c77ec811f4b0b8e5 (diff) | |
download | perl-dbc63d465574018de759a7737c0926b69e546aa6.tar.gz |
File::Path::mkpath reports the wrong error
Message-ID: <19981021131203.A15661@excitecorp.com>
p4raw-id: //depot/perl@2069
Diffstat (limited to 'lib')
-rw-r--r-- | lib/File/Path.pm | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/File/Path.pm b/lib/File/Path.pm index 09c52a4e1b..225ecab4b6 100644 --- a/lib/File/Path.pm +++ b/lib/File/Path.pm @@ -135,8 +135,9 @@ sub mkpath { } print "mkdir $path\n" if $verbose; unless (mkdir($path,$mode)) { - # allow for another process to have created it meanwhile - croak "mkdir $path: $!" unless -d $path; + my $e = $!; + # allow for another process to have created it meanwhile + croak "mkdir $path: $e" unless -d $path; } push(@created, $path); } |