mirror of
https://github.com/reactos/reactos.git
synced 2025-07-14 00:34:14 +00:00
Fix some possible problems
svn path=/trunk/; revision=31091
This commit is contained in:
parent
24707452c1
commit
8366ad6ef8
1 changed files with 4 additions and 3 deletions
|
@ -222,7 +222,7 @@ InstallDevice(
|
||||||
NtClose(hDeviceKey);
|
NtClose(hDeviceKey);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
else
|
else if (pPartialInformation)
|
||||||
{
|
{
|
||||||
for (HardwareID = (LPCWSTR)pPartialInformation->Data;
|
for (HardwareID = (LPCWSTR)pPartialInformation->Data;
|
||||||
(PUCHAR)HardwareID < pPartialInformation->Data + pPartialInformation->DataLength
|
(PUCHAR)HardwareID < pPartialInformation->Data + pPartialInformation->DataLength
|
||||||
|
@ -277,7 +277,7 @@ InstallDevice(
|
||||||
DPRINT1("NtQueryValueKey() failed with status 0x%08x\n", Status);
|
DPRINT1("NtQueryValueKey() failed with status 0x%08x\n", Status);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
else
|
else if (pPartialInformation)
|
||||||
{
|
{
|
||||||
for (HardwareID = (LPCWSTR)pPartialInformation->Data;
|
for (HardwareID = (LPCWSTR)pPartialInformation->Data;
|
||||||
(PUCHAR)HardwareID < pPartialInformation->Data + pPartialInformation->DataLength
|
(PUCHAR)HardwareID < pPartialInformation->Data + pPartialInformation->DataLength
|
||||||
|
@ -347,7 +347,8 @@ EventThread(IN LPVOID lpParameter)
|
||||||
if (Status == STATUS_BUFFER_TOO_SMALL)
|
if (Status == STATUS_BUFFER_TOO_SMALL)
|
||||||
{
|
{
|
||||||
PnpEventSize += 0x400;
|
PnpEventSize += 0x400;
|
||||||
PnpEvent = (PPLUGPLAY_EVENT_BLOCK)RtlReAllocateHeap(ProcessHeap, 0, PnpEvent, PnpEventSize);
|
RtlFreeHeap(ProcessHeap, 0, PnpEvent);
|
||||||
|
PnpEvent = (PPLUGPLAY_EVENT_BLOCK)RtlAllocateHeap(ProcessHeap, 0, PnpEventSize);
|
||||||
if (PnpEvent == NULL)
|
if (PnpEvent == NULL)
|
||||||
{
|
{
|
||||||
NtClose(hEnum);
|
NtClose(hEnum);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue