diff options
| author | Sarita Patra <saritap@vmware.com> | 2019-02-22 01:59:07 -0800 | 
|---|---|---|
| committer | Sarita Patra <saritap@vmware.com> | 2019-02-24 21:26:58 -0800 | 
| commit | 957d93eaf2ce5fe4969b406dc5e44677bf60ce5b (patch) | |
| tree | f993a2975b1dcb9f9d6f6a741db3860290319193 /pimd/pim_rpf.c | |
| parent | d8bed89dca5955fe298c108afe78b13a95469cea (diff) | |
pimd: Handling Null incoming interface of dummy upstream
When FRR receives IGMP/PIM (*, G) join and RP is not configured or not
reachable, then we are creating a dummy upstream with incoming interface
as NULL and upstream address as INADDR_ANY.
Added upstream address and incoming interface validation where it is necessary,
before doing any operation on the upstream.
Signed-off-by: Sarita Patra <saritap@vmware.com>
Diffstat (limited to 'pimd/pim_rpf.c')
| -rw-r--r-- | pimd/pim_rpf.c | 6 | 
1 files changed, 6 insertions, 0 deletions
diff --git a/pimd/pim_rpf.c b/pimd/pim_rpf.c index 814d2e076b..d689b276b7 100644 --- a/pimd/pim_rpf.c +++ b/pimd/pim_rpf.c @@ -205,6 +205,12 @@ enum pim_rpf_result pim_rpf_update(struct pim_instance *pim,  	struct prefix src, grp;  	bool neigh_needed = true; +	if (up->upstream_addr.s_addr == INADDR_ANY) { +		zlog_debug("%s: RP is not configured yet for %s", +			__PRETTY_FUNCTION__, up->sg_str); +		return PIM_RPF_OK; +	} +  	saved.source_nexthop = rpf->source_nexthop;  	saved.rpf_addr = rpf->rpf_addr;  | 
