WineHQ
Bug Tracking Database – Bug 56940

 Bugzilla

 

Last modified: 2024-12-13 21:36:45 UTC  

vs_community.exe halts:"The application cannot find one of its required files, possibly because it was unable to create it in the folder."

Bug 56940 - vs_community.exe halts:"The application cannot find one of its required files, possibly because it was unable to create it in the folder."
vs_community.exe halts:"The application cannot find one of its required files...
Status: CLOSED FIXED
AppDB: Show Apps affected by this bug
Product: Wine
Classification: Unclassified
Component: shell32
9.12
x86-64 Linux
: P2 normal
: ---
Assigned To: Mr. Bugs
https://aka.ms/vs/16/release/vs_commu...
: download, regression
Depends on:
Blocks:
  Show dependency tree
 
Reported: 2024-07-06 13:57 UTC by Louis Lenders
Modified: 2024-12-13 21:36 UTC (History)
2 users (show)

See Also:
Regression SHA1: 0bad544aab9e2c9ee93bbabac0386e02c58a39c0
Fixed by SHA1: 448fcbc0c60d7228ed52f1f5d90f62be0a58289a
Distribution: Debian
Staged patchset:


Attachments
test executable (16.00 KB, application/x-msdownload)
2024-07-09 17:45 UTC, Louis Lenders
Details
patch (1.50 KB, patch)
2024-07-13 20:45 UTC, Louis Lenders
Details | Diff
updated patch (1.87 KB, patch)
2024-11-18 22:00 UTC, Louis Lenders
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Louis Lenders 2024-07-06 13:57:48 UTC
Note: I installed .net48 beforehand

It throws this error, whereas before the regression you can enter the initial menu correctly.

0bad544aab9e2c9ee93bbabac0386e02c58a39c0 is the first bad commit
commit 0bad544aab9e2c9ee93bbabac0386e02c58a39c0
Author: Yuxuan Shui <yshui@codeweavers.com>
Date:   Mon May 20 09:51:07 2024 +0100

    shell32: Fix ShellExecute for non-filespec paths.

 dlls/shell32/shlexec.c       | 60 +++++++++++++++++++++++++++++++++++++++++++++++-------------
 dlls/shell32/tests/shlexec.c | 13 ++++++++++++-
 2 files changed, 59 insertions(+), 14 deletions(-)
Comment 1 Louis Lenders 2024-07-06 14:05:42 UTC
added dl link
Comment 2 Louis Lenders 2024-07-06 14:11:10 UTC
Hi, i cannot add the author of patch in the CC field, because email-address seems unknown(?). Any one know correct email-address?
Comment 3 Fabian Maurer 2024-07-06 14:34:38 UTC
Maybe they don't have a bugzilla account?

Maybe we should ping them on the MR? https://gitlab.winehq.org/wine/wine/-/merge_requests/5692
Comment 4 Louis Lenders 2024-07-06 14:44:46 UTC
(In reply to Fabian Maurer from comment #3)
> Maybe they don't have a bugzilla account?
> 
> Maybe we should ping them on the MR?
> https://gitlab.winehq.org/wine/wine/-/merge_requests/5692

Thanks, I dropped a note there. Also paste some debug output below, might or might not help to see why it fails ;)

0024:trace:exec:SHELL_execute mask=0x00000540 hwnd=00000000 verb=L"runas" file=L"vs_bootstrapper_d15\\vs_setup_bootstrapper.exe " parm=L"  --env \"_SFX_CAB_EXE_PACKAGE:Z:\\home\\louis\\ramdisk\\vs_Community.exe _SFX_CAB_EXE_ORIGINALWORKINGDIR:Z:\\home\\louis\\sda3\\wine\"" dir=L"C:\\users\\louis\\Temp\\3252d0f1a378a23b87c1ac\\" show=0x00000005 class=not used
0024:fixme:exec:SHELL_execute flags ignored: 0x00000100
0024:trace:exec:ShellExecute_FromContextMenu L"vs_bootstrapper_d15\\vs_setup_bootstrapper.exe "
0024:trace:exec:ShellExecute_GetClassKey ext = L""
0024:trace:exec:ShellExecute_GetClassKey class = (null)
0024:trace:exec:SHELL_execute execute:L"vs_bootstrapper_d15\\vs_setup_bootstrapper.exe ",L"  --env \"_SFX_CAB_EXE_PACKAGE:Z:\\home\\louis\\ramdisk\\vs_Community.exe _SFX_CAB_EXE_ORIGINALWORKINGDIR:Z:\\home\\louis\\sda3\\wine\"",L"C:\\users\\louis\\Temp\\3252d0f1a378a23b87c1ac\\"
0024:trace:exec:SHELL_FindExecutable L"vs_bootstrapper_d15\\vs_setup_bootstrapper.exe "
0024:trace:exec:SHELL_FindExecutable ASDF L"C:\\users\\louis\\Temp\\3252d0f1a378a23b87c1ac\\"
0024:trace:shell:PathFileExistsDefExtW (L"C:\\users\\louis\\Temp\\3252d0f1a378a23b87c1ac\\vs_bootstrapper_d15\\vs_setup_bootstrapper.exe ",191)
0024:trace:shell:PathFileExistsDefExtW (L"vs_bootstrapper_d15\\vs_setup_bootstrapper.exe ",191)
0024:trace:exec:SHELL_FindExecutable Returning SE_ERR_FNF
0024:trace:shell:PathIsDirectoryW (L"vs_bootstrapper_d15\\vs_setup_bootstrapper.exe ")
0024:trace:exec:SHELL_execute retval 2
Comment 5 Gijs Vermeulen 2024-07-06 14:49:12 UTC
Adding 'regression' keyword and CC'ing patch author.
Comment 6 Louis Lenders 2024-07-09 10:24:37 UTC
I tried follow code path in current shell32, and maybe the troubles is caused by the trailing space in the filepath: "...vs_setup_bootstrapper.exe "

(PathFileExistsDefExtW (L"vs_bootstrapper_d15\\vs_setup_bootstrapper.exe ",191)

If I strip that space manually away with a hack, the installer works again. But that needs some testing first for I guess PathFileExistsDefExtW
Comment 7 Louis Lenders 2024-07-09 17:45:10 UTC
Created attachment 76768 [details]
test executable

Attached a small test executable

On windows this will start regedit, on wine it does nothing...

After long search, if I'm correct, the problem is in ShellExecuteW. Source for simple test:

#include <windows.h>
#include <shellapi.h>

int __cdecl main(int argc, CHAR *arg[])
{
    
ShellExecuteW( NULL, L"open", L"regedit.exe ", NULL, NULL, SW_SHOWNORMAL );

}

Wine's ShellExecuteW doesn't like the trailing space, but windows seems to happily execute the app.

I'll see if I can fixup a patch
Comment 8 Louis Lenders 2024-07-13 20:45:10 UTC
Created attachment 76791 [details]
patch

Attached patch (+tests) fixes this bug.

Will send later to wine-gitlab for review.
Comment 9 Fabian Maurer 2024-07-13 20:56:18 UTC
FWIW, it only seems to be normal space characters that are allowed. tab, newline, linefeed, non-breaking space and zero width space don't work.
Comment 10 Louis Lenders 2024-11-18 22:00:04 UTC
Created attachment 77425 [details]
updated patch

Updated patch, the previous patch was wrong I think as lpFile is a const wchar, which it was trying to modify.
Comment 11 yshuiv7 2024-11-19 11:14:41 UTC
Hi, thanks for triaging the bug and providing a patch! Can you submit your patch as an MR here: https://gitlab.winehq.org?
Comment 12 Hans Leidekker 2024-12-11 09:50:28 UTC
It would be nice to get this regression fixed during code freeze. Louis, are you interested in submitting your patch? If not, let us know and we can take care of it.
Comment 13 Hans Leidekker 2024-12-13 08:38:54 UTC
Fixed with 448fcbc0c60d7228ed52f1f5d90f62be0a58289a.
Comment 14 Alexandre Julliard 2024-12-13 21:36:45 UTC
Closing bugs fixed in 10.0-rc2.


Privacy Policy
If you have a privacy inquiry regarding this site, please write to [email protected]

Hosted By CodeWeavers