in reply to Re^2: delete duplicates in windows subdirectories
in thread delete duplicates in windows subdirectories
has a precedence problem. If the open fails then it will not execute the die (and we not not saying why the open failed). A better way is:open FILE,$file || die "Cant open $file!\n";
oropen (FILE,$file) || die "Cant open $file: $!\n";
or even betteropen FILE,$file or die "Cant open $file: $!\n";
Then change the occurences of FILE to $fh.open (my $fh, '<', $file) || die "Cannot open $file: $!";
|
|---|