diff options
author | Donald Sharp <sharpd@cumulusnetwroks.com> | 2016-08-15 18:04:30 +0200 |
---|---|---|
committer | Donald Sharp <sharpd@cumulusnetwroks.com> | 2016-08-15 18:52:05 +0200 |
commit | 352534ac21dd985fa3b5c71a0276849cb7a71633 (patch) | |
tree | 1884e13463b061683b3875ce5fc39be701204be7 /zebra/rt_netlink.c | |
parent | zebra: Fix interface lookup for RA statistics (diff) | |
download | frr-352534ac21dd985fa3b5c71a0276849cb7a71633.tar.xz frr-352534ac21dd985fa3b5c71a0276849cb7a71633.zip |
zebra: Fix usage of accidental NULL pointer
NS_DEFAULT is #defined to 0, We are passing it
in to a function that is taking 'struct zebra_ns *'
which is translating into a NULL pointer. Which
in some situations will cause a crash.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Reviewed-by: Don Slice <dslice@cumulusnetworks.com>
Daniel Walton <dwalton@cumulusnetworks.com>
Nikolay Aleksandrov <nikolay@cumulusnetworks.com>
(cherry picked from commit 1e9fa2763953adc603c3acc4ed2a46c9e72cbb29)
(cherry picked from commit e33efc8aa85ad17698bd8d42f1d32d80eb5ca4b6)
Diffstat (limited to '')
-rw-r--r-- | zebra/rt_netlink.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/zebra/rt_netlink.c b/zebra/rt_netlink.c index 481ff781e..054990065 100644 --- a/zebra/rt_netlink.c +++ b/zebra/rt_netlink.c @@ -1998,7 +1998,7 @@ netlink_neigh_update (int cmd, int ifindex, __u32 addr, char *lla, int llalen) addattr_l(&req.n, sizeof(req), NDA_DST, &addr, 4); addattr_l(&req.n, sizeof(req), NDA_LLADDR, lla, llalen); - return netlink_talk (&req.n, &zns->netlink_cmd, NS_DEFAULT); + return netlink_talk (&req.n, &zns->netlink_cmd, zns); } /* Routing table change via netlink interface. */ |