summaryrefslogtreecommitdiff
path: root/pimd/pim_msg.c
diff options
context:
space:
mode:
authorDonald Sharp <sharpd@cumulusnetworks.com>2016-08-05 09:07:46 -0400
committerDonald Sharp <sharpd@cumulusnetworks.com>2016-12-21 20:26:05 -0500
commit75a26779e8f25e9868f1f33e0fd35677f17c978b (patch)
tree095795d5b355c285bc7c1683c2ca2b072255cfec /pimd/pim_msg.c
parentdc686f820be848d9b80e3f3918228d6eb321c826 (diff)
pimd: Refactor RP code and start the ability to handle ranges
Refactor the qpim_rp into pim_rp.c so that the global data is protected. This will allow us to easily add the group ranges. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Diffstat (limited to 'pimd/pim_msg.c')
-rw-r--r--pimd/pim_msg.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/pimd/pim_msg.c b/pimd/pim_msg.c
index 61fc480bf9..df7f7051d3 100644
--- a/pimd/pim_msg.c
+++ b/pimd/pim_msg.c
@@ -25,10 +25,12 @@
#include "log.h"
#include "pimd.h"
+#include "pim_vty.h"
#include "pim_pim.h"
#include "pim_msg.h"
#include "pim_util.h"
#include "pim_str.h"
+#include "pim_rp.h"
void pim_msg_build_header(uint8_t *pim_msg, int pim_msg_size,
uint8_t pim_msg_type)
@@ -177,8 +179,9 @@ pim_msg_join_prune_encode (uint8_t *buf, int buf_size, int is_join,
remain = end - pim_msg_curr;
if (source.s_addr == INADDR_ANY)
{
+ struct pim_rpf *rpf = pim_rp_g (group);
bits = PIM_ENCODE_SPARSE_BIT | PIM_ENCODE_WC_BIT | PIM_ENCODE_RPT_BIT;
- stosend = qpim_rp.rpf_addr;
+ stosend = rpf->rpf_addr;
}
else
{