mirror of
https://github.com/reactos/reactos.git
synced 2025-02-28 19:32:59 +00:00
[NTDLL] check for NULL buffer in LdrpLoadDll
This happens in advapi32_apitest in Test_CreateOpenKey.
This commit is contained in:
parent
486ab63862
commit
90dce9340c
1 changed files with 6 additions and 0 deletions
|
@ -2423,6 +2423,12 @@ LdrpLoadDll(IN BOOLEAN Redirected,
|
|||
PLDR_DATA_TABLE_ENTRY LdrEntry;
|
||||
BOOLEAN InInit = LdrpInLdrInit;
|
||||
|
||||
if (DllName->Buffer == NULL)
|
||||
{
|
||||
DPRINT1("DllName->Buffer is NULL!\n");
|
||||
return STATUS_INVALID_PARAMETER;
|
||||
}
|
||||
|
||||
/* Save the Raw DLL Name */
|
||||
if (DllName->Length >= sizeof(NameBuffer)) return STATUS_NAME_TOO_LONG;
|
||||
RtlInitEmptyUnicodeString(&RawDllName, NameBuffer, sizeof(NameBuffer));
|
||||
|
|
Loading…
Reference in a new issue