[PATCH v7 2/2] ntdll: Prevent loading Wine system dependencies in place of identically named application DLLs.
Zebediah Figura (she/her)
zfigura at codeweavers.com
Fri Nov 12 11:31:32 CST 2021
On 11/12/21 11:24, Alexandre Julliard wrote:
> "Zebediah Figura (she/her)" <zfigura at codeweavers.com> writes:
>
>> On 11/12/21 09:22, Alexandre Julliard wrote:
>>> Zebediah Figura <zfigura at codeweavers.com> writes:
>>>
>>>> @@ -3027,6 +3035,12 @@ static NTSTATUS load_dll( const WCHAR *load_path, const WCHAR *libname, const WC
>>>> break;
>>>> }
>>>> + /* mark the DLL as system only if it was loaded from a
>>>> system path and is
>>>> + * not builtin. note that builtins can appear to be loaded from a system
>>>> + * path during prefix bootstrap */
>>>> + if (!((*pwm)->ldr.Flags & LDR_WINE_INTERNAL))
>>>> + (*pwm)->system = system;
>>> I think that even during bootstrap we need to find builtins if they
>>> already exist. Most likely you should bypass the bootstrap fallback
>>> during system dll search.
>>
>> Sorry, I'm not sure I understand? We do find builtins if they already
>> exist with this patch; we just don't mark them as system libraries.
>
> My reading is that in bootstrap mode, the initial search for system
> libraries is going to fall back to find_builtin_without_file(), so we'll
> never go on to actually searching the prefix.
>
> What we want is to search for the builtin everywhere possible, and only
> fall back to find_builtin_without_file() if it doesn't exist at all.
>
Thanks, that makes sense.
More information about the wine-devel
mailing list