DSDV: Modify rarely-used keywords to comply with other compilers

This commit is contained in:
John Abraham
2013-07-11 09:27:37 -07:00
parent ab023f5a25
commit fc07a2195e
3 changed files with 9 additions and 9 deletions

View File

@@ -691,7 +691,7 @@ RoutingProtocol::RecvDsdv (Ptr<Socket> socket)
/*Received update with same seq number but with same or greater hop count.
* Discard that update.
*/
if (not m_advRoutingTable.AnyRunningEvent (dsdvHeader.GetDst ()))
if (!m_advRoutingTable.AnyRunningEvent (dsdvHeader.GetDst ()))
{
/*update the timer only if nexthop address matches thus discarding
* updates to that destination from other nodes.
@@ -711,7 +711,7 @@ RoutingProtocol::RecvDsdv (Ptr<Socket> socket)
else
{
// Received update with an old sequence number. Discard the update
if (not m_advRoutingTable.AnyRunningEvent (dsdvHeader.GetDst ()))
if (!m_advRoutingTable.AnyRunningEvent (dsdvHeader.GetDst ()))
{
m_advRoutingTable.DeleteRoute (dsdvHeader.GetDst ());
}
@@ -743,7 +743,7 @@ RoutingProtocol::RecvDsdv (Ptr<Socket> socket)
}
else
{
if (not m_advRoutingTable.AnyRunningEvent (dsdvHeader.GetDst ()))
if (!m_advRoutingTable.AnyRunningEvent (dsdvHeader.GetDst ()))
{
m_advRoutingTable.DeleteRoute (dsdvHeader.GetDst ());
}
@@ -786,7 +786,7 @@ RoutingProtocol::SendTriggeredUpdate ()
<< " SeqNo:" << i->second.GetSeqNo () << " HopCount:"
<< i->second.GetHop () + 1);
RoutingTableEntry temp = i->second;
if ((i->second.GetEntriesChanged () == true) && (not m_advRoutingTable.AnyRunningEvent (temp.GetDestination ())))
if ((i->second.GetEntriesChanged () == true) && (!m_advRoutingTable.AnyRunningEvent (temp.GetDestination ())))
{
dsdvHeader.SetDst (i->second.GetDestination ());
dsdvHeader.SetDstSeqno (i->second.GetSeqNo ());
@@ -1189,7 +1189,7 @@ RoutingProtocol::MergeTriggerPeriodicUpdates ()
for (std::map<Ipv4Address, RoutingTableEntry>::const_iterator i = allRoutes.begin (); i != allRoutes.end (); ++i)
{
RoutingTableEntry advEntry = i->second;
if ((advEntry.GetEntriesChanged () == true) && (not m_advRoutingTable.AnyRunningEvent (advEntry.GetDestination ())))
if ((advEntry.GetEntriesChanged () == true) && (!m_advRoutingTable.AnyRunningEvent (advEntry.GetDestination ())))
{
if (!(advEntry.GetSeqNo () % 2))
{

View File

@@ -39,9 +39,9 @@ namespace ns3 {
namespace dsdv {
RoutingTableEntry::RoutingTableEntry (Ptr<NetDevice> dev,
Ipv4Address dst,
u_int32_t seqNo,
uint32_t seqNo,
Ipv4InterfaceAddress iface,
u_int32_t hops,
uint32_t hops,
Ipv4Address nextHop,
Time lifetime,
Time SettlingTime,

View File

@@ -57,8 +57,8 @@ class RoutingTableEntry
{
public:
/// c-tor
RoutingTableEntry (Ptr<NetDevice> dev = 0, Ipv4Address dst = Ipv4Address (), u_int32_t m_seqNo = 0,
Ipv4InterfaceAddress iface = Ipv4InterfaceAddress (), u_int32_t hops = 0, Ipv4Address nextHop = Ipv4Address (),
RoutingTableEntry (Ptr<NetDevice> dev = 0, Ipv4Address dst = Ipv4Address (), uint32_t m_seqNo = 0,
Ipv4InterfaceAddress iface = Ipv4InterfaceAddress (), uint32_t hops = 0, Ipv4Address nextHop = Ipv4Address (),
Time lifetime = Simulator::Now (), Time SettlingTime = Simulator::Now (), bool changedEntries = false);
~RoutingTableEntry ();