diff --git a/pimd/pim_register.c b/pimd/pim_register.c index 3b48232391..013f04bb00 100644 --- a/pimd/pim_register.c +++ b/pimd/pim_register.c @@ -452,7 +452,7 @@ int pim_register_recv(struct interface *ifp, struct in_addr dest_addr, } if ((upstream->sptbit == PIM_UPSTREAM_SPTBIT_TRUE) - || ((SwitchToSptDesired(pim_ifp->pim, &sg)) + || ((SwitchToSptDesiredOnRp(pim_ifp->pim, &sg)) && pim_upstream_inherited_olist(pim_ifp->pim, upstream) == 0)) { pim_register_stop_send(ifp, &sg, dest_addr, src_addr); @@ -463,7 +463,7 @@ int pim_register_recv(struct interface *ifp, struct in_addr dest_addr, upstream->sptbit); } if ((upstream->sptbit == PIM_UPSTREAM_SPTBIT_TRUE) - || (SwitchToSptDesired(pim_ifp->pim, &sg))) { + || (SwitchToSptDesiredOnRp(pim_ifp->pim, &sg))) { if (sentRegisterStop) { pim_upstream_keep_alive_timer_start( upstream, diff --git a/pimd/pim_upstream.c b/pimd/pim_upstream.c index 673c56ea5d..a42df54393 100644 --- a/pimd/pim_upstream.c +++ b/pimd/pim_upstream.c @@ -1425,7 +1425,7 @@ void pim_upstream_msdp_reg_timer_start(struct pim_upstream *up) * SwitchToSptDesired(S,G) return true once a single packet has been * received for the source and group. */ -int pim_upstream_switch_to_spt_desired(struct pim_instance *pim, +int pim_upstream_switch_to_spt_desired_on_rp(struct pim_instance *pim, struct prefix_sg *sg) { if (I_am_RP(pim, sg->grp)) diff --git a/pimd/pim_upstream.h b/pimd/pim_upstream.h index bb0921e108..ab50820518 100644 --- a/pimd/pim_upstream.h +++ b/pimd/pim_upstream.h @@ -292,9 +292,9 @@ void pim_upstream_update_my_assert_metric(struct pim_upstream *up); void pim_upstream_keep_alive_timer_start(struct pim_upstream *up, uint32_t time); -int pim_upstream_switch_to_spt_desired(struct pim_instance *pim, +int pim_upstream_switch_to_spt_desired_on_rp(struct pim_instance *pim, struct prefix_sg *sg); -#define SwitchToSptDesired(pim, sg) pim_upstream_switch_to_spt_desired (pim, sg) +#define SwitchToSptDesiredOnRp(pim, sg) pim_upstream_switch_to_spt_desired_on_rp (pim, sg) int pim_upstream_is_sg_rpt(struct pim_upstream *up); void pim_upstream_set_sptbit(struct pim_upstream *up,