A couple of suggestions:
In reply to Re: Closing a filehandle in ":unix" layer doesn't work on Win32 by BrowserUk in thread Closing a filehandle in ":unix" layer doesn't work on Win32 by rovf