Am 25.01.25 um 09:32 schrieb Patrick Steinhardt: > The user report was explicitly about compatibility with JGit, which > still had these files open. We don't have control over third-party > clients and how exactly they open files, so it is expected that we may > still see failures with the deletion of in-use files. Fair enough. > I'd be happy to hear about alternative ideas that didn't came to my > mind. Instead of calling _wunlink() in mingw_unlink, we could CreateFileW() with access mode DELETE and flag FILE_FLAG_DELETE_ON_CLOSE, then close the file right away. That would apply semantics that is similar, but not quite, POSIX at least among the files that we open ourselves. It would be even better that we do not depend on the POSIX behavior in the first place. As you said, the reftable library can live with failed deletes. And I don't think we depend on the POSIX behavior anywhere else because we would see the "try again?" question much more frequently than we do right now. -- Hannes