diff options
| author | David Lamparter <equinox@diac24.net> | 2017-04-05 22:32:46 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2017-04-05 22:32:46 +0200 |
| commit | 606eb3ad7cef75cc7374b2ea11b6470d09ef0975 (patch) | |
| tree | 082c0936bed46b2d289a25ee32b371f74aed587c /pimd/pim_mroute.c | |
| parent | cfb38409e397b34e8f14a9617a086be4043861a3 (diff) | |
| parent | a7b2b1e29862f82d8a68bda2c72a460cd26aa5a8 (diff) | |
Merge pull request #337 from donaldsharp/more_spt_more
More spt more
Diffstat (limited to 'pimd/pim_mroute.c')
| -rw-r--r-- | pimd/pim_mroute.c | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/pimd/pim_mroute.c b/pimd/pim_mroute.c index 2fb243b9bd..1df4c033bc 100644 --- a/pimd/pim_mroute.c +++ b/pimd/pim_mroute.c @@ -200,6 +200,30 @@ pim_mroute_msg_wholepkt (int fd, struct interface *ifp, const char *buf) up = pim_upstream_find(&sg); if (!up) { + struct prefix_sg star = sg; + star.src.s_addr = INADDR_ANY; + + up = pim_upstream_find(&star); + + if (up && PIM_UPSTREAM_FLAG_TEST_SRC_IGMP(up->flags)) + { + up = pim_upstream_add (&sg, ifp, PIM_UPSTREAM_FLAG_MASK_SRC_LHR, __PRETTY_FUNCTION__); + if (!up) + { + if (PIM_DEBUG_MROUTE) + zlog_debug ("%s: Unable to create upstream information for %s", + __PRETTY_FUNCTION__, pim_str_sg_dump (&sg)); + return 0; + } + pim_upstream_keep_alive_timer_start (up, qpim_keep_alive_time); + pim_upstream_inherited_olist (up); + pim_upstream_switch(up, PIM_UPSTREAM_JOINED); + + if (PIM_DEBUG_MROUTE) + zlog_debug ("%s: Creating %s upstream on LHR", + __PRETTY_FUNCTION__, up->sg_str); + return 0; + } if (PIM_DEBUG_MROUTE_DETAIL) { zlog_debug("%s: Unable to find upstream channel WHOLEPKT%s", __PRETTY_FUNCTION__, pim_str_sg_dump (&sg)); |
