--- a/RELEASE_NOTES Tue Jun 17 22:44:08 2014 +0200
+++ b/RELEASE_NOTES Tue Jun 17 23:31:52 2014 +0200
@@ -25,6 +25,7 @@
Bugs fixed
----------
- Bug 1930 - Use of invalid reference in OLSR RemoveLinkTuple
+- Bug 1932 - NdiscCache entry is not failsafe on double neighbor probing.
Known issues
------------
--- a/src/internet/model/icmpv6-l4-protocol.cc Tue Jun 17 22:44:08 2014 +0200
+++ b/src/internet/model/icmpv6-l4-protocol.cc Tue Jun 17 23:31:52 2014 +0200
@@ -1340,7 +1340,7 @@
*hardwareDestination = entry->GetMacAddress ();
return true;
}
- else /* PROBE */
+ else /* INCOMPLETE or PROBE */
{
/* queue packet */
entry->AddWaitingPacket (p);
--- a/src/internet/model/ndisc-cache.cc Tue Jun 17 22:44:08 2014 +0200
+++ b/src/internet/model/ndisc-cache.cc Tue Jun 17 23:31:52 2014 +0200
@@ -367,6 +367,10 @@
void NdiscCache::Entry::StartReachableTimer ()
{
NS_LOG_FUNCTION_NOARGS ();
+ if (m_reachableTimer.IsRunning ())
+ {
+ m_reachableTimer.Cancel ();
+ }
m_reachableTimer.SetFunction (&NdiscCache::Entry::FunctionReachableTimeout, this);
m_reachableTimer.SetDelay (MilliSeconds (Icmpv6L4Protocol::REACHABLE_TIME));
m_reachableTimer.Schedule ();
@@ -381,6 +385,10 @@
void NdiscCache::Entry::StartProbeTimer ()
{
NS_LOG_FUNCTION_NOARGS ();
+ if (m_probeTimer.IsRunning ())
+ {
+ m_probeTimer.Cancel ();
+ }
m_probeTimer.SetFunction (&NdiscCache::Entry::FunctionProbeTimeout, this);
m_probeTimer.SetDelay (MilliSeconds (Icmpv6L4Protocol::RETRANS_TIMER));
m_probeTimer.Schedule ();
@@ -397,6 +405,10 @@
void NdiscCache::Entry::StartDelayTimer ()
{
NS_LOG_FUNCTION_NOARGS ();
+ if (m_delayTimer.IsRunning ())
+ {
+ m_delayTimer.Cancel ();
+ }
m_delayTimer.SetFunction (&NdiscCache::Entry::FunctionDelayTimeout, this);
m_delayTimer.SetDelay (Seconds (Icmpv6L4Protocol::DELAY_FIRST_PROBE_TIME));
m_delayTimer.Schedule ();
@@ -412,6 +424,10 @@
void NdiscCache::Entry::StartRetransmitTimer ()
{
NS_LOG_FUNCTION_NOARGS ();
+ if (m_retransTimer.IsRunning ())
+ {
+ m_retransTimer.Cancel ();
+ }
m_retransTimer.SetFunction (&NdiscCache::Entry::FunctionRetransmitTimeout, this);
m_retransTimer.SetDelay (MilliSeconds (Icmpv6L4Protocol::RETRANS_TIMER));
m_retransTimer.Schedule ();