https://bugs.winehq.org/show_bug.cgi?id=48902
Bug ID: 48902 Summary: Warframe launcher fails to replace updated Launcher.exe the first time (works when Retry option pressed, as Launcher.exe deleted first time) Product: Wine Version: 5.4 Hardware: x86 OS: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: kernel32 Assignee: wine-bugs@winehq.org Reporter: wine.bugzilla@johnthomson.fastmail.com.au Distribution: ---
Created attachment 66856 --> https://bugs.winehq.org/attachment.cgi?id=66856 trace+file,trace+ntdll,trace+server,+relay truncated
Warframe launcher When a Launcher.exe update is available, the update will be downloaded and extracted as Launcher.exe.tmp. Then replace Launcher.exe with Launcher.exe.tmp. This is first attempted with MoveFileEx, then MoveFileWithProgressW Launcher.exe.tmp Launcher.exe nil nil 0001 (MOVEFILE_REPLACE_EXISTING)
The game's user/Local\ Settings/Application\ Data/Warframe/Launcher.log shows these errors: MoveFileEx 0x5 Access denied ReplaceFile 0x497 Unable to remove the file to be replaced
In moving the replaced file out of the way, a temp file is created, and the replaced file is moved to this temp file This temp file is then deleted with: NtCreateFile(&hFile, SYNCHRONIZE | DELETE, //access mask &attr, &io, NULL, 0, FILE_SHARE_READ | FILE_SHARE_WRITE | FILE_SHARE_DELETE, //sharing FILE_OPEN, //disposition FILE_DELETE_ON_CLOSE | FILE_NON_DIRECTORY_FILE, //options NULL, 0);
This fails in server/fd.c check_sharing if ((existing_access & FILE_MAPPING_IMAGE) && (options & FILE_DELETE_ON_CLOSE)) return STATUS_CANNOT_DELETE; A printf here showed: existing_access=2684354560 FILE_MAPPING_IMAGE=80000000 options=00001040 FILE_DELETE_ON_CLOSE=00001000
Launcher.exe is no longer in place, as it was moved to the temp file. Launcher.exe.tmp remains.
The launcher shows an error about this replacement failure, with a retry option. The replacement works at retry, because the Launcher.exe file no longer exists.
https://bugs.winehq.org/show_bug.cgi?id=48902
Zebediah Figura z.figura12@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |z.figura12@gmail.com
--- Comment #1 from Zebediah Figura z.figura12@gmail.com --- This was probably already fixed by bae4776c571cf975be1689594f4caf93ad23e0ca, or is this with current git?
https://bugs.winehq.org/show_bug.cgi?id=48902
--- Comment #2 from wine.bugzilla@johnthomson.fastmail.com.au --- Created attachment 66857 --> https://bugs.winehq.org/attachment.cgi?id=66857 trace+file,trace+ntdll,trace+server,+relay truncated fixed
https://bugs.winehq.org/show_bug.cgi?id=48902
wine.bugzilla@johnthomson.fastmail.com.au changed:
What |Removed |Added ---------------------------------------------------------------------------- Regression SHA1| |5e218fe758fe6beed5c7ad73405 | |eccf33c307e6d
--- Comment #3 from wine.bugzilla@johnthomson.fastmail.com.au --- Yes, resolved, fixed by bae4776c571cf975be1689594f4caf93ad23e0ca. I couldn't set the regression and fixed-by in the same comment. Cheers
https://bugs.winehq.org/show_bug.cgi?id=48902
wine.bugzilla@johnthomson.fastmail.com.au changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |RESOLVED Resolution|--- |FIXED Fixed by SHA1| |bae4776c571cf975be1689594f4 | |caf93ad23e0ca
--- Comment #4 from wine.bugzilla@johnthomson.fastmail.com.au --- Fixed by bae4776c571cf975be1689594f4caf93ad23e0ca
https://bugs.winehq.org/show_bug.cgi?id=48902
Zebediah Figura z.figura12@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Keywords| |regression
https://bugs.winehq.org/show_bug.cgi?id=48902
Alexandre Julliard julliard@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #5 from Alexandre Julliard julliard@winehq.org --- Closing bugs fixed in 5.6.