mirror of
https://github.com/ApfelTeeSaft/reactos.git
synced 2026-09-02 19:26:32 +00:00
- Fix 3 handle leaks
- Fix 2 memory leaks svn path=/branches/aicom-network-fixes/; revision=36115
This commit is contained in:
@@ -283,6 +283,7 @@ NdisOpenProtocolConfiguration(
|
||||
if(!ConfigurationContext)
|
||||
{
|
||||
NDIS_DbgPrint(MIN_TRACE,("Insufficient resources.\n"));
|
||||
ZwClose(KeyHandle);
|
||||
*ConfigurationHandle = NULL;
|
||||
*Status = NDIS_STATUS_FAILURE;
|
||||
return;
|
||||
@@ -849,6 +850,7 @@ NdisOpenConfigurationKeyByIndex(
|
||||
if(!ConfigurationContext)
|
||||
{
|
||||
NDIS_DbgPrint(MIN_TRACE,("Insufficient resources.\n"));
|
||||
ZwClose(RegKeyHandle);
|
||||
*Status = NDIS_STATUS_FAILURE;
|
||||
return;
|
||||
}
|
||||
@@ -907,6 +909,7 @@ NdisOpenConfigurationKeyByName(
|
||||
if(!ConfigurationContext)
|
||||
{
|
||||
NDIS_DbgPrint(MIN_TRACE,("Insufficient resources.\n"));
|
||||
ZwClose(RegKeyHandle);
|
||||
*Status = NDIS_STATUS_FAILURE;
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -407,6 +407,7 @@ NdisMAllocateMapRegisters(
|
||||
if(!NT_SUCCESS(NtStatus))
|
||||
{
|
||||
NDIS_DbgPrint(MIN_TRACE, ("IoAllocateAdapterChannel failed: 0x%x\n", NtStatus));
|
||||
ExFreePool(Adapter->MapRegisters);
|
||||
return NDIS_STATUS_RESOURCES;
|
||||
}
|
||||
|
||||
@@ -417,6 +418,7 @@ NdisMAllocateMapRegisters(
|
||||
if(!NT_SUCCESS(NtStatus))
|
||||
{
|
||||
NDIS_DbgPrint(MIN_TRACE, ("KeWaitForSingleObject failed: 0x%x\n", NtStatus));
|
||||
ExFreePool(Adapter->MapRegisters);
|
||||
return NDIS_STATUS_RESOURCES;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user