mirror of
https://github.com/ApfelTeeSaft/reactos.git
synced 2026-09-03 04:13:31 +00:00
[NTOS:IO] Do not ignore RtlDuplicateUnicodeString return value
CORE-17637
This commit is contained in:
committed by
Jérôme Gardou
parent
cf1a95a588
commit
838abc475c
@@ -1396,6 +1396,14 @@ IopSetServiceEnumData(
|
||||
goto done;
|
||||
}
|
||||
|
||||
Status = RtlDuplicateUnicodeString(RTL_DUPLICATE_UNICODE_STRING_ALLOCATE_NULL_STRING,
|
||||
&ServiceName,
|
||||
&DeviceNode->ServiceName);
|
||||
if (!NT_SUCCESS(Status))
|
||||
{
|
||||
goto done;
|
||||
}
|
||||
|
||||
RtlInitUnicodeString(&EnumKeyName, L"Enum");
|
||||
Status = IopCreateRegistryKeyEx(&ServiceEnumKey,
|
||||
ServiceKey,
|
||||
@@ -1480,10 +1488,6 @@ IopSetServiceEnumData(
|
||||
sizeof(NextInstance));
|
||||
}
|
||||
|
||||
RtlDuplicateUnicodeString(RTL_DUPLICATE_UNICODE_STRING_ALLOCATE_NULL_STRING,
|
||||
&ServiceName,
|
||||
&DeviceNode->ServiceName);
|
||||
|
||||
done:
|
||||
if (ServiceEnumKey != NULL)
|
||||
ZwClose(ServiceEnumKey);
|
||||
|
||||
Reference in New Issue
Block a user