[darcs-users] disposing of files (on win32)
Trent W. Buck
twb at cybersource.com.au
Thu Jul 30 06:04:27 UTC 2009
Petr Rockai <me at mornfall.net> writes:
> although impossibility to delete open files on windows is a way to
> catch descriptor leaks, it is also a source of constant problems. I
> have thought a little about this, and would like to propose following:
>
> When running on windows, have a _darcs/trash directory, and instead of
> calling removeFile, we rename the file into _darcs/trash and provide
> an atexit handler that removes anything in the trash. I have checked,
> that renaming a file is OK even while it is open, on windows.
Even if it is an inter-device move? Hmm, I suppose _darcs, unlike
%APPDATA%/darcs, is very unlikely to have that problem...
More information about the darcs-users
mailing list