]> git.proxmox.com Git - mirror_frr.git/blobdiff - pimd/pim_join.c
Merge pull request #5288 from SumitAgarwal123/bfd_docs
[mirror_frr.git] / pimd / pim_join.c
index 686475fefe3a05ef77a52142ade19ab0343c0f70..89be42842ee32f1e5c23b046f2a5ea6fd6e1d0c9 100644 (file)
@@ -83,6 +83,11 @@ static void recv_join(struct interface *ifp, struct pim_neighbor *neigh,
            && (source_flags & PIM_WILDCARD_BIT_MASK)) {
                struct pim_rpf *rp = RP(pim_ifp->pim, sg->grp);
 
+               if (!rp) {
+                       zlog_warn("%s: Lookup of RP failed for %pSG4",
+                                 __PRETTY_FUNCTION__, sg);
+                       return;
+               }
                /*
                 * If the RP sent in the message is not
                 * our RP for the group, drop the message
@@ -136,6 +141,12 @@ static void recv_prune(struct interface *ifp, struct pim_neighbor *neigh,
            && (source_flags & PIM_WILDCARD_BIT_MASK)) {
                struct pim_rpf *rp = RP(pim_ifp->pim, sg->grp);
 
+               if (!rp) {
+                       if (PIM_DEBUG_PIM_TRACE)
+                               zlog_debug("%s: RP for %pSG4 completely failed lookup",
+                                          __PRETTY_FUNCTION__, sg);
+                       return;
+               }
                // Ignoring Prune *,G's at the moment.
                if (sg->src.s_addr != rp->rpf_addr.u.prefix4.s_addr)
                        return;
@@ -332,7 +343,7 @@ int pim_joinprune_recv(struct interface *ifp, struct pim_neighbor *neigh,
                                struct pim_upstream *up = sg_ch->upstream;
                                PIM_IF_FLAG_SET_S_G_RPT(sg_ch->flags);
                                if (up) {
-                                       if (PIM_DEBUG_TRACE)
+                                       if (PIM_DEBUG_PIM_TRACE)
                                                zlog_debug(
                                                        "%s: SGRpt flag is set, del inherit oif from up %s",
                                                        __PRETTY_FUNCTION__,