in reply to Re: Perl Warning Help
in thread Perl Warning Help

Well, I don't do Windows, but I'm pretty sure it would be better to use the inbuilt unlink command instead of system.

if (-e $fn) { unlink $fn or die "Can't remove $fn"; }

Note that this will not work on directories (use rmdir for that).


Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it. -- Brian W. Kernighan