Script runs fine for me; no crashes. Windows 2008 R2, Perl 5.12.4.
I suspect you're triggering some sort of race condition in Windows' file locking, but even if I removed the print to STDOUT to try to speed things up, I wasn't able to trigger it. Sleeping for a few microseconds before calling rename might help.
In reply to Re: Rename unreliable on Windows
by tobyink
in thread Rename unreliable on Windows
by elef
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |