From 2f2b10d22b1413ea69bccd55f3f3039d4cc914f4 Mon Sep 17 00:00:00 2001 From: Craig Dowell Date: Fri, 13 Jul 2007 14:35:24 -0700 Subject: [PATCH] remove inappropriate assertions that popped when routing disabled --- src/routing/static-route-manager.cc | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/routing/static-route-manager.cc b/src/routing/static-route-manager.cc index 3e8e43fd7..3c37389cf 100644 --- a/src/routing/static-route-manager.cc +++ b/src/routing/static-route-manager.cc @@ -145,7 +145,11 @@ StaticRouteManager::BuildStaticRoutingDatabase () Ptr rtr = node->QueryInterface (StaticRouter::iid); - NS_ASSERT_MSG(rtr, "QI for interface failed"); + + if (!rtr) + { + continue; + } // You must call DiscoverLSAs () before trying to use any // routing info or to update LSAs. Subsequently you may use @@ -208,7 +212,7 @@ StaticRouteManager::InitializeRoutes () Ptr rtr = node->QueryInterface (StaticRouter::iid); - NS_ASSERT_MSG(rtr, "QI for interface failed"); + if (rtr && rtr->GetNumLSAs () ) { SPFCalculate(rtr->GetRouterId ());