http://bugs.winehq.org/show_bug.cgi?id=58435
Bug ID: 58435 Summary: winepath -w conversion outputs wrong filenames Product: Wine Version: 10.11 Hardware: x86-64 OS: Linux Status: NEW Severity: normal Priority: P2 Component: kernel32 Assignee: wine-bugs@winehq.org Reporter: madewokherd@gmail.com Distribution: ---
Observed in the pipeline failure here: https://gitlab.winehq.org/mono/wine-mono/-/jobs/169670
The build script in Wine Mono uses winepath -w to get a windows path for one of its outputs. The command, though not logged, would have been: winepath -w /builds/mono/wine-mono/build/winemono-support.cab Based on debugging in other places, I think that outputs: Z:\builds\mono\wine-mono\build\winemono-supporpport.cab
96cd811903e3d3f227c39e12235725baf793f4b9 is the first bad commit commit 96cd811903e3d3f227c39e12235725baf793f4b9 Author: Alexandre Julliard julliard@winehq.org Date: Tue Jun 24 11:56:39 2025 +0200
kernel32: Reimplement conversion to DOS name using GetFinalPathNameByHandleW.
dlls/kernel32/path.c | 44 +++++++++++++++++++++++++++++++++++--------- 1 file changed, 35 insertions(+), 9 deletions(-)
The pattern seems to be that it fails when given an absolute path to a file that does not exist. The directory that would contain the file must exist or it won't output anything.
The result seems to always be <path with last 5 characters cut off> + <last 9 characters of path>.
http://bugs.winehq.org/show_bug.cgi?id=58435
Esme Povirk madewokherd@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Regression SHA1| |96cd811903e3d3f227c39e12235 | |725baf793f4b9 CC| |madewokherd@gmail.com Keywords| |regression, source
http://bugs.winehq.org/show_bug.cgi?id=58435
--- Comment #1 from Esme Povirk madewokherd@gmail.com --- https://gitlab.winehq.org/wine/wine/-/merge_requests/8455 looks related.