Subject: | Problem with copying |
Can't work out why, but I can't seem to get no return code from this module.
This is my script, using 0.07
#! /usr/bin/perl -w
use File::Copy::Recursive;
my($nfdirs,$ndirs,$depth) = File::Copy::Recursive::rcopy("testdir", "newtestdir");
print "NF $nfdirs,ND $ndirs,D $depth: $@\n";
I create the testdir with mkdir can cat so it looks like testdir/mytest/junk.txt
junk.txt is a 0 length file. Tried it with some junk text in too.
Running the above command I get the whole hierarchy copied as I might expect, but apparently undef is returned.
corsair$ perl foo.pl
Use of uninitialized value in concatenation (.) or string at foo.pl line 6.
Use of uninitialized value in concatenation (.) or string at foo.pl line 6.
Use of uninitialized value in concatenation (.) or string at foo.pl line 6.
NF ,ND ,D :
corsair$
corsair$ perl -v
This is perl, v5.8.0 built for i386-linux-thread-multi
(with 1 registered patch, see perl -V for more detail)
I tried tracing through with the debugger, is seems to return from $recurse skipping most calls (e.g. straight back to my call).
I tried it under cygwin under windows 2000 (This is perl, v5.8.7 built for cygwin-thread-multi-64int) and got the same results.