ntdll: Allow 16-bit executables to be loaded from build directory.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=51214 Signed-off-by: Bernhard Übelacker <bernhardu@mailbox.org> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
be55038f3d
commit
cbf7a10176
|
@ -2675,6 +2675,7 @@ static NTSTATUS find_builtin_without_file( const WCHAR *name, UNICODE_STRING *ne
|
|||
|
||||
if (!get_env_var( L"WINEBUILDDIR", 20 + 2 * wcslen(name), new_name ))
|
||||
{
|
||||
len = new_name->Length;
|
||||
RtlAppendUnicodeToString( new_name, L"\\dlls\\" );
|
||||
RtlAppendUnicodeToString( new_name, name );
|
||||
if ((ext = wcsrchr( name, '.' )) && !wcscmp( ext, L".dll" )) new_name->Length -= 4 * sizeof(WCHAR);
|
||||
|
@ -2685,6 +2686,17 @@ static NTSTATUS find_builtin_without_file( const WCHAR *name, UNICODE_STRING *ne
|
|||
RtlAppendUnicodeToString( new_name, L".fake" );
|
||||
status = open_dll_file( new_name, pwm, mapping, image_info, id );
|
||||
if (status != STATUS_DLL_NOT_FOUND) goto done;
|
||||
|
||||
new_name->Length = len;
|
||||
RtlAppendUnicodeToString( new_name, L"\\programs\\" );
|
||||
RtlAppendUnicodeToString( new_name, name );
|
||||
RtlAppendUnicodeToString( new_name, L"\\" );
|
||||
RtlAppendUnicodeToString( new_name, name );
|
||||
status = open_dll_file( new_name, pwm, mapping, image_info, id );
|
||||
if (status != STATUS_DLL_NOT_FOUND) goto done;
|
||||
RtlAppendUnicodeToString( new_name, L".fake" );
|
||||
status = open_dll_file( new_name, pwm, mapping, image_info, id );
|
||||
if (status != STATUS_DLL_NOT_FOUND) goto done;
|
||||
RtlFreeUnicodeString( new_name );
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue