in reply to Re: Catching . .. in file listing
in thread Catching . .. in file listing

my @GPS = grep { -f "$new_dir/$_" } readdir($dh);

It looks like the OP is on Windows so this is a bit OT but if you were on *nix you might want to consider adding and not -l "$new_dir/$_" into the grep depending on how you want to treat symbolic links.

I hope this is of interest.

Cheers,

JohnGG