in reply to Closing a filehandle in ":unix" layer doesn't work on Win32

Update: "If I comment out the binmode statement and run the program, the file is deleted properly." missed on the first go round. First, I would check to see if you have permissions to delete the file.

If that is fine, then I would test to see if the behavior changes if you isolate the block that uses $fh (my $fh ... $fh->close) with a block or a sub. How about if you do a $fh = undef; after the close?

--MidLifeXis

Replies are listed 'Best First'.
Re^2: Closing a filehandle in ":unix" layer doesn't work on Win32
by rovf (Priest) on Mar 28, 2011 at 13:28 UTC
    Nice ideas, but no change in effect. Actually, if my explicit closing of the file handle doesn't help, I would not expect that going out of scope would do any difference.....

    -- 
    Ronald Fischer <ynnor@mm.st>