https://bugs.winehq.org/show_bug.cgi?id=46554
Bug ID: 46554 Summary: DeleteFile can't handle broken symlinks (target removed before symlink) Product: Wine Version: 4.0-rc7 Hardware: x86-64 OS: Linux Status: NEW Keywords: source, testcase Severity: normal Priority: P2 Component: kernel32 Assignee: wine-bugs@winehq.org Reporter: gijsvrm@gmail.com Distribution: ArchLinux
Created attachment 63426 --> https://bugs.winehq.org/attachment.cgi?id=63426 testcase
While working on a CreateSymbolicLink implementation, I noticed it was causing test failures in msvcp120. While investigating, I noticed some of the created symlinks weren't getting deleted. Swapping the order of deletion to make sure all symlinks are removed before the targets fixed the test failures.
Attached you can find a patch that includes my WIP CreateSymbolicLink implementation and some DeleteFileA tests that prove that this works on Windows, but doesn't on Wine. As I said before, removing the symlinks and then removing the targets works fine.
Beware that my test will leave behind a file, the aforementioned broken symlink.
https://bugs.winehq.org/show_bug.cgi?id=46554
--- Comment #1 from Gijs Vermeulen gijsvrm@gmail.com --- Created attachment 63544 --> https://bugs.winehq.org/attachment.cgi?id=63544 hack patch
Attached hack fixes the issue, but it's definitely not the right place to fix it.
https://bugs.winehq.org/show_bug.cgi?id=46554
Gijs Vermeulen gijsvrm@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution|--- |ABANDONED
--- Comment #2 from Gijs Vermeulen gijsvrm@gmail.com --- This was probably fixed by Erich's rework of the CreateSymbolicLink rework, abandoning.
https://bugs.winehq.org/show_bug.cgi?id=46554
Gijs Vermeulen gijsvrm@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #3 from Gijs Vermeulen gijsvrm@gmail.com --- Closing