diff --git a/src/olsr/model/olsr-routing-protocol.cc b/src/olsr/model/olsr-routing-protocol.cc index c2dc2eb2a..5bf417f92 100644 --- a/src/olsr/model/olsr-routing-protocol.cc +++ b/src/olsr/model/olsr-routing-protocol.cc @@ -2359,31 +2359,31 @@ RoutingProtocol::PopulateMprSelectorSet(const olsr::MessageHeader& msg, /// \param p the packet which couldn't be delivered by the MAC layer. /// void -OLSR::mac_failed (Ptr p) +OLSR::mac_failed(Ptr p) { - double now = Simulator::Now (); - struct hdr_ip* ih = HDR_IP (p); - struct hdr_cmn* ch = HDR_CMN (p); + double now = Simulator::Now (); + struct hdr_ip* ih = HDR_IP (p); + struct hdr_cmn* ch = HDR_CMN (p); - debug ("%f: Node %d MAC Layer detects a breakage on link to %d\n", - now, - OLSR::node_id (ra_addr ()), - OLSR::node_id (ch->next_hop ())); + debug("%f: Node %d MAC Layer detects a breakage on link to %d\n", + now, + OLSR::node_id (ra_addr ()), + OLSR::node_id (ch->next_hop ())); - if ((uint32_t)ih->daddr () == IP_BROADCAST) + if ((uint32_t)ih->daddr () == IP_BROADCAST) { - drop (p, DROP_RTR_MAC_CALLBACK); - return; + drop (p, DROP_RTR_MAC_CALLBACK); + return; } - OLSR_link_tuple* link_tuple = state_.find_link_tuple (ch->next_hop ()); - if (link_tuple) + OLSR_link_tuple* link_tuple = state_.find_link_tuple(ch->next_hop()); + if (link_tuple) { - link_tuple->lost_time () = now + OLSR_NEIGHB_HOLD_TIME; - link_tuple->time () = now + OLSR_NEIGHB_HOLD_TIME; - nb_loss (link_tuple); + link_tuple->lost_time() = now + OLSR_NEIGHB_HOLD_TIME; + link_tuple->time() = now + OLSR_NEIGHB_HOLD_TIME; + nb_loss(link_tuple); } - drop (p, DROP_RTR_MAC_CALLBACK); + drop(p, DROP_RTR_MAC_CALLBACK); } #endif