diff options
author | Stephen Worley <sworley@cumulusnetworks.com> | 2020-04-09 01:09:29 +0200 |
---|---|---|
committer | Stephen Worley <sworley@cumulusnetworks.com> | 2020-04-10 01:04:45 +0200 |
commit | b6d34c260939cdcf7bba327108d2de35fc58fb54 (patch) | |
tree | 67e1f866a9f13695149ff98505d95d30f26822ba /zebra/rule_netlink.c | |
parent | pbrd: separate `set *` and `no set *` commands (diff) | |
download | frr-b6d34c260939cdcf7bba327108d2de35fc58fb54.tar.xz frr-b6d34c260939cdcf7bba327108d2de35fc58fb54.zip |
zebra: set family on read in rule prefix
We were not setting the family for the prefix on the src/dst
IP of the rule.
Signed-off-by: Stephen Worley <sworley@cumulusnetworks.com>
Diffstat (limited to 'zebra/rule_netlink.c')
-rw-r--r-- | zebra/rule_netlink.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/zebra/rule_netlink.c b/zebra/rule_netlink.c index 34df2485c..a361f73c1 100644 --- a/zebra/rule_netlink.c +++ b/zebra/rule_netlink.c @@ -271,6 +271,7 @@ int netlink_rule_change(struct nlmsghdr *h, ns_id_t ns_id, int startup) memcpy(&rule.rule.filter.src_ip.u.prefix6, RTA_DATA(tb[FRA_SRC]), 16); rule.rule.filter.src_ip.prefixlen = frh->src_len; + rule.rule.filter.src_ip.family = frh->family; rule.rule.filter.filter_bm |= PBR_FILTER_SRC_IP; } @@ -282,6 +283,7 @@ int netlink_rule_change(struct nlmsghdr *h, ns_id_t ns_id, int startup) memcpy(&rule.rule.filter.dst_ip.u.prefix6, RTA_DATA(tb[FRA_DST]), 16); rule.rule.filter.dst_ip.prefixlen = frh->dst_len; + rule.rule.filter.dst_ip.family = frh->family; rule.rule.filter.filter_bm |= PBR_FILTER_DST_IP; } |