X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2FFile%2FCopy.pm;h=e6cf78603423dd55a9efc3f8b284dace6b164e41;hb=e1b504a6228ce3e510cdb12230253e594379395e;hp=8638bee2108ea412590fc5422e6958cf92c5cb97;hpb=17f410f9a3a4ae9cda502b59b391e6653db436ce;p=p5sagit%2Fp5-mst-13.2.git diff --git a/lib/File/Copy.pm b/lib/File/Copy.pm index 8638bee..e6cf786 100644 --- a/lib/File/Copy.pm +++ b/lib/File/Copy.pm @@ -83,7 +83,7 @@ sub copy { if ($from_a_handle) { *FROM = *$from{FILEHANDLE}; } else { - $from = "./$from" if $from =~ /^\s/; + $from = "./$from" if $from =~ /^\s/s; open(FROM, "< $from\0") or goto fail_open1; binmode FROM or die "($!,$^E)"; $closefrom = 1; @@ -92,7 +92,7 @@ sub copy { if ($to_a_handle) { *TO = *$to{FILEHANDLE}; } else { - $to = "./$to" if $to =~ /^\s/; + $to = "./$to" if $to =~ /^\s/s; open(TO,"> $to\0") or goto fail_open2; binmode TO or die "($!,$^E)"; $closeto = 1;