From: Gurusamy Sarathy Date: Tue, 21 Mar 2000 03:34:39 +0000 (+0000) Subject: $File::Find::name doesn't reflect top level files X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=719911cc0ef424f213e0e6e02359decafbe1180f;p=p5sagit%2Fp5-mst-13.2.git $File::Find::name doesn't reflect top level files correctly (from Simon Cozens ) p4raw-id: //depot/perl@5849 --- diff --git a/lib/File/Find.pm b/lib/File/Find.pm index 22a8ab3..ac73f1b 100644 --- a/lib/File/Find.pm +++ b/lib/File/Find.pm @@ -349,7 +349,7 @@ sub _find_opt { unless ($Is_Dir) { unless (($_,$dir) = File::Basename::fileparse($abs_dir)) { - ($dir,$_) = ('.', $top_item); + ($dir,$_) = ('./', $top_item); } $abs_dir = $dir; @@ -370,9 +370,9 @@ sub _find_opt { warn "Couldn't chdir $abs_dir: $!\n"; next Proc_Top_Item; } - - $name = $abs_dir; - + + $name = $abs_dir . $_; + &$wanted_callback; }