## In a different session from which I will run my modified version of your script C:\test>echo xx > ttz C:\test>handle | find "ttz" ## shows that immediately after creation, nothing has an open handle to that file ## Now in the other session C:\test>junk44 Permission denied : The process cannot access the file because it is being used by another process at C:\test\junk44.pl line 12. ## And back in the first session whilst the 10 second sleep is running C:\test>handle | find "ttz" 60: File (RW-) C:\test\ttz