src/internet-stack/ipv4-l3-protocol.cc
changeset 4669 8aaa5e83939e
parent 4616 a84f60b6cd12
child 5121 872e554039c3
child 5204 cb3087d8f330
child 5595 7c769a64cbd4
equal deleted inserted replaced
4668:010500125723 4669:8aaa5e83939e
   144  * by setting the node in the ipv4 stack
   144  * by setting the node in the ipv4 stack
   145  */
   145  */
   146 void
   146 void
   147 Ipv4L3Protocol::NotifyNewAggregate ()
   147 Ipv4L3Protocol::NotifyNewAggregate ()
   148 {
   148 {
   149   Ptr<Node>node = this->GetObject<Node>();
   149   if (m_node == 0)
   150   // verify that it's a valid node and that
   150     {
   151   // the node has not been set before
   151       Ptr<Node>node = this->GetObject<Node>();
   152   if (node!= 0 && m_node == 0)
   152       // verify that it's a valid node and that
   153     {
   153       // the node has not been set before
   154       this->SetNode (node);
   154       if (node != 0)
       
   155         {
       
   156           this->SetNode (node);
       
   157         }
   155     }
   158     }
   156   Object::NotifyNewAggregate ();
   159   Object::NotifyNewAggregate ();
   157 }
   160 }
   158 
   161 
   159 void 
   162 void