]> git.proxmox.com Git - mirror_frr.git/commitdiff
pimd: Lookup S,G ifchannel after we create it
authorDonald Sharp <sharpd@cumulusnetworks.com>
Thu, 3 Aug 2017 14:56:30 +0000 (10:56 -0400)
committerDonald Sharp <sharpd@cumulusnetworks.com>
Thu, 3 Aug 2017 22:24:28 +0000 (18:24 -0400)
There are situations where we receive a *,G with
a S,G,RPT Prune embedded where we do not actually
have any S,G yet(MSDP with multiple RP's with the
same address).  As such since we only need to
lookup the S,G ifchannel once, do it after
the recv_prune.

Ticket: CM-17230
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
pimd/pim_join.c

index 9796f580cefa7df58cae59c778b9014b6cce6767..c60e5a65aaee8826eaf084a18e492539b6c16bf8 100644 (file)
@@ -306,14 +306,20 @@ int pim_joinprune_recv(struct interface *ifp, struct pim_neighbor *neigh,
                                return -8;
                        }
 
-                       sg_ch = pim_ifchannel_find(ifp, &sg);
-
                        buf += addr_offset;
                        starg_alone = 0;
                        recv_prune(ifp, neigh, msg_holdtime,
                                   msg_upstream_addr.u.prefix4, &sg,
                                   msg_source_flags);
 
+                       /*
+                        * So if we are receiving a S,G,RPT prune
+                        * before we have any data for that S,G
+                        * We need to retrieve the sg_ch after
+                        * we parse the prune.
+                        */
+                       sg_ch = pim_ifchannel_find(ifp, &sg);
+
                        /* Received SG-RPT Prune delete oif from specific S,G */
                        if (starg_ch && sg_ch
                            && (msg_source_flags & PIM_RPT_BIT_MASK)