Bug 407 postfix: filter out non-OLSR interfaces when generating MID messages
authorLalith Suresh <suresh.lalith@gmail.com>
Thu, 18 Mar 2010 10:50:44 +0000
changeset 6142 c5b36fbaa9c8
parent 6141 3adf94e68d82
child 6143 ad316b5cfb5a
Bug 407 postfix: filter out non-OLSR interfaces when generating MID messages
src/routing/olsr/olsr-routing-protocol.cc
--- a/src/routing/olsr/olsr-routing-protocol.cc	Wed Mar 17 16:58:32 2010 +0000
+++ b/src/routing/olsr/olsr-routing-protocol.cc	Thu Mar 18 10:50:44 2010 +0000
@@ -1751,7 +1751,7 @@
   for (uint32_t i = 0; i < m_ipv4->GetNInterfaces (); i++)
     {
       Ipv4Address addr = m_ipv4->GetAddress (i, 0).GetLocal ();
-      if (addr != m_mainAddress && addr != loopback)
+      if (addr != m_mainAddress && addr != loopback && m_interfaceExclusions.find (i) == m_interfaceExclusions.end ())
         mid.interfaceAddresses.push_back (addr);
     }
   if (mid.interfaceAddresses.size () == 0)
@@ -2603,7 +2603,6 @@
 
 ///
 /// \brief Sends a MID message (if the node has more than one interface) and resets the MID timer.
-/// \warning Currently it does nothing because there is no support for multiple interfaces.
 /// \param e The event which has expired.
 ///
 void
@@ -2788,7 +2787,6 @@
 
 ///
 /// \brief Removes tuple_ if expired. Else timer is rescheduled to expire at tuple_->time().
-/// \warning Actually this is never invoked because there is no support for multiple interfaces.
 /// \param e The event which has expired.
 ///
 void