]> git.puffer.fish Git - mirror/frr.git/commitdiff
ospf6d: increment dbdesc seqnum on SeqNumberMismatch/BadLsReq event
authorDinesh Dutt <ddutt@cumulusnetworks.com>
Sun, 25 Aug 2013 03:03:15 +0000 (03:03 +0000)
committerDavid Lamparter <equinox@opensourcerouting.org>
Fri, 8 Nov 2013 02:15:43 +0000 (18:15 -0800)
As per RFC 2328, section 10.3, if the neighbor state machine reaches
SeqNumberMismatch state when the NSM is in state Exchange or greater,
"router increments the DD sequence number in the neighbor data structure,
declares itself master (sets the master/slave bit to master), and starts
sending Database Description Packets, with the initialize (I), more (M)
and master (MS) bits set.".

The existing code doesn't increment the DD SeqNum. This patch fixes that.

Signed-off-by: Dinesh G Dutt <ddutt at cumulusnetworks.com>
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
ospf6d/ospf6_neighbor.c

index 84f0b002c4a682f842453b165ac3c09ff94ba4f4..b7d2e40dbd7a160b278dcbb84dfca988eecda0ff 100644 (file)
@@ -484,6 +484,8 @@ seqnumber_mismatch (struct thread *thread)
     }
 
   THREAD_OFF (on->thread_send_dbdesc);
+  on->dbdesc_seqnum++;         /* Incr seqnum as per RFC2328, sec 10.3 */
+
   on->thread_send_dbdesc =
     thread_add_event (master, ospf6_dbdesc_send, on, 0);
 
@@ -520,6 +522,8 @@ bad_lsreq (struct thread *thread)
     }
 
   THREAD_OFF (on->thread_send_dbdesc);
+  on->dbdesc_seqnum++;         /* Incr seqnum as per RFC2328, sec 10.3 */
+
   on->thread_send_dbdesc =
     thread_add_event (master, ospf6_dbdesc_send, on, 0);