I have a question regarding this statement... sub fixdir { my $dir = shift; opendir my $DH, $dir or die "Not Found....$dir: $!"; while (my $f = readdir $DH) { next if grep $_ eq $f, qw/. ../; (my $new = $f) =~ s/[^a-zA-Z0-9_.]/_/g; next if ($new eq $f); <<<<<<<<<<<<< THIS ONE <<<<<<<<<<<<<<<< while ( -e "$dir/$new") { $new.= "1"; } print STDERR "Renaming: $f -> $new\n"; rename "$dir/$f", "$dir/$new"; fixdir("$dir/$new") if -d "$dir/$new"; } } IF $f is the name of a directory and not a file won't that whole directory get skipped????? Thanks -Ray