mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-07 21:54:01 +00:00
pimd: ch->upstream cannot be NULL
in pim_ifchannel.c there exists several spots where the ch->upstream is assumed to be NULL. This is not possible. Signed-off-by: Donald Sharp <sharpd@nvidia.com>
This commit is contained in:
parent
7fc3f834e9
commit
29b458ef1f
@ -539,10 +539,7 @@ struct pim_ifchannel *pim_ifchannel_add(struct interface *ifp, pim_sgaddr *sg,
|
|||||||
if (up_flags == PIM_UPSTREAM_FLAG_MASK_SRC_IGMP)
|
if (up_flags == PIM_UPSTREAM_FLAG_MASK_SRC_IGMP)
|
||||||
PIM_IF_FLAG_SET_PROTO_IGMP(ch->flags);
|
PIM_IF_FLAG_SET_PROTO_IGMP(ch->flags);
|
||||||
|
|
||||||
if (ch->upstream)
|
|
||||||
ch->upstream->flags |= up_flags;
|
ch->upstream->flags |= up_flags;
|
||||||
else if (PIM_DEBUG_EVENTS)
|
|
||||||
zlog_debug("%s:%pSG No Upstream found", __func__, sg);
|
|
||||||
|
|
||||||
return ch;
|
return ch;
|
||||||
}
|
}
|
||||||
@ -637,7 +634,6 @@ static void ifjoin_to_noinfo(struct pim_ifchannel *ch)
|
|||||||
pim_ifchannel_ifjoin_switch(__func__, ch, PIM_IFJOIN_NOINFO);
|
pim_ifchannel_ifjoin_switch(__func__, ch, PIM_IFJOIN_NOINFO);
|
||||||
pim_forward_stop(ch);
|
pim_forward_stop(ch);
|
||||||
|
|
||||||
if (ch->upstream)
|
|
||||||
PIM_UPSTREAM_FLAG_UNSET_SRC_PIM(ch->upstream->flags);
|
PIM_UPSTREAM_FLAG_UNSET_SRC_PIM(ch->upstream->flags);
|
||||||
|
|
||||||
PIM_IF_FLAG_UNSET_PROTO_PIM(ch->flags);
|
PIM_IF_FLAG_UNSET_PROTO_PIM(ch->flags);
|
||||||
@ -696,7 +692,6 @@ static void on_ifjoin_prune_pending_timer(struct thread *t)
|
|||||||
* message on RP path upon prune timer expiry.
|
* message on RP path upon prune timer expiry.
|
||||||
*/
|
*/
|
||||||
ch->ifjoin_state = PIM_IFJOIN_PRUNE;
|
ch->ifjoin_state = PIM_IFJOIN_PRUNE;
|
||||||
if (ch->upstream) {
|
|
||||||
struct pim_upstream *parent =
|
struct pim_upstream *parent =
|
||||||
ch->upstream->parent;
|
ch->upstream->parent;
|
||||||
|
|
||||||
@ -721,7 +716,6 @@ static void on_ifjoin_prune_pending_timer(struct thread *t)
|
|||||||
ch->upstream->channel_oil,
|
ch->upstream->channel_oil,
|
||||||
__func__);
|
__func__);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
/* from here ch may have been deleted */
|
/* from here ch may have been deleted */
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user