https://bugs.winehq.org/show_bug.cgi?id=49593
--- Comment #2 from xantares xantares09@hotmail.com --- I think it could come from dlls/ntdll/env.c:
static void get_image_path( const char *argv0, UNICODE_STRING *path ) ... /* check for builtin path inside system directory */ if (!is_path_prefix( system_dir, full_name, file_part )) { if (!is_win64 && !is_wow64) goto failed; if (!is_path_prefix( syswow64_dir, full_name, file_part )) goto failed; } ... failed: MESSAGE( "wine: cannot find '%s'\n", argv0 ); RtlExitUserProcess( GetLastError() );
here it seems no error was set and GetLastError may return 0
a proposal would be to return CTL_E_FILENOTFOUND