mirror of
https://github.com/reactos/reactos.git
synced 2025-08-03 20:05:41 +00:00
[NTOSKRNL]
Prevent potential double free in loop. Fixes CID 732510 svn path=/trunk/; revision=58916
This commit is contained in:
parent
703a1db75e
commit
ec1a8a5a63
1 changed files with 6 additions and 2 deletions
|
@ -367,7 +367,11 @@ IopLogWorker(IN PVOID Parameter)
|
||||||
DeviceNameLength += sizeof(WCHAR);
|
DeviceNameLength += sizeof(WCHAR);
|
||||||
|
|
||||||
/* Free the buffer if we had one */
|
/* Free the buffer if we had one */
|
||||||
if (PoolObjectNameInfo) ExFreePool(PoolObjectNameInfo);
|
if (PoolObjectNameInfo)
|
||||||
|
{
|
||||||
|
ExFreePool(PoolObjectNameInfo);
|
||||||
|
PoolObjectNameInfo = NULL;
|
||||||
|
}
|
||||||
|
|
||||||
/* Go to the next string buffer position */
|
/* Go to the next string buffer position */
|
||||||
ErrorMessage->EntryData.NumberOfStrings++;
|
ErrorMessage->EntryData.NumberOfStrings++;
|
||||||
|
@ -428,7 +432,7 @@ IopLogWorker(IN PVOID Parameter)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Derefernece the device object */
|
/* Dereference the device object */
|
||||||
if (LogEntry->DeviceObject) ObDereferenceObject(LogEntry->DeviceObject);
|
if (LogEntry->DeviceObject) ObDereferenceObject(LogEntry->DeviceObject);
|
||||||
if (DriverObject) ObDereferenceObject(LogEntry->DriverObject);
|
if (DriverObject) ObDereferenceObject(LogEntry->DriverObject);
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue