Author: cgutman Date: Fri Aug 29 21:04:30 2008 New Revision: 35783
URL: http://svn.reactos.org/svn/reactos?rev=35783&view=rev Log: - Check that we successfully allocated memory - Return TDI_NO_RESOURCES instead of STATUS_NO_MEMORY
Modified: branches/aicom-network-fixes/drivers/network/tcpip/tcpip/ninfo.c
Modified: branches/aicom-network-fixes/drivers/network/tcpip/tcpip/ninfo.c URL: http://svn.reactos.org/svn/reactos/branches/aicom-network-fixes/drivers/netw... ============================================================================== --- branches/aicom-network-fixes/drivers/network/tcpip/tcpip/ninfo.c [iso-8859-1] (original) +++ branches/aicom-network-fixes/drivers/network/tcpip/tcpip/ninfo.c [iso-8859-1] Fri Aug 29 21:04:30 2008 @@ -26,6 +26,9 @@ IF_LIST_ITER(CurrentIF);
TI_DbgPrint(DEBUG_INFO, ("Called.\n")); + + if (!IpAddress) + return TDI_NO_RESOURCES;
TcpipAcquireSpinLock(&InterfaceListLock, &OldIrql);
@@ -80,7 +83,7 @@ if( !RCache || !RouteEntries ) { if( RCache ) ExFreePool( RCache ); if( RouteEntries ) ExFreePool( RouteEntries ); - return STATUS_NO_MEMORY; + return TDI_NO_RESOURCES; }
RtlZeroMemory( RouteEntries, Size );