- Return early if NBAddNeighbor or RouterAddRoute fails

- Fixes coverity error 389

svn path=/branches/aicom-network-fixes/; revision=36526
This commit is contained in:
Cameron Gutman 2008-09-26 03:23:56 +00:00
parent 9023e12475
commit d9db39f82d

View file

@ -242,12 +242,14 @@ VOID IPAddInterfaceRoute( PIP_INTERFACE IF ) {
NUD_PERMANENT);
if (!NCE) {
TI_DbgPrint(MIN_TRACE, ("Could not create NCE.\n"));
return;
}
AddrWidenAddress( &NetworkAddress, &IF->Unicast, &IF->Netmask );
if (!RouterAddRoute(&NetworkAddress, &IF->Netmask, NCE, 1)) {
TI_DbgPrint(MIN_TRACE, ("Could not add route due to insufficient resources.\n"));
return;
}
/* Allow TCP to hang some configuration on this interface */