For a long time we've worked around `killdir` sometimes failing to cleanup 
working.tmp on Windows, leaving one or more files in the directory, by trying 
to clean it up next time instead. There also used to be some bugs causing files 
or directories to be undeletable, e.g. because SDL_mixer or DIR (which 
internally keeps a persistent handle returned by FindFiles) held them open, but 
no such unfixed bugs are known to me.

Someone mentioned that using Distribute Game sometimes doesn't clean up its 
temp directory afterwards.

I think what is causing killdir to fail is that an external program, namely a 
virus scanner or file indexer, is momentarily reading a file after we write, 
the same cause as bug #36. However this problem will need to be worked around 
separately.

Normally when you try to delete a file Windows marks it for deletion once 
everyone has closed it (unless someone opens it without `FILE_SHARE_DELETE`, in 
which case `DeleteFile` fails). I wonder if it has an API for deleting 
directories that works similarly. But most likely we just have to try again 
later if deleting the directory or a file in it failed.


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/ohrrpgce/ohrrpgce/issues/39
_______________________________________________
Ohrrpgce mailing list
ohrrpgce@lists.motherhamster.org
http://lists.motherhamster.org/listinfo.cgi/ohrrpgce-motherhamster.org

Reply via email to