diff options
| author | Donald Sharp <sharpd@cumulusnetworks.com> | 2017-08-24 19:54:21 -0400 |
|---|---|---|
| committer | Donald Sharp <sharpd@cumulusnetworks.com> | 2017-08-24 20:34:28 -0400 |
| commit | e691f179b6c6fc26536e68958f19ff6983a03274 (patch) | |
| tree | 9b00aba37c7ce79b5f51b314d1a7aa66fa127682 /pimd/pim_zebra.c | |
| parent | cc9b06ad5e58968356ab4edf30f3fd9eb7583b47 (diff) | |
pimd: Cleanup a variety of SA issues
1) Error check return from setsockopt and sockets
2) Check return codes for str2prefix
3) Clean up some potential NULL References
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Diffstat (limited to 'pimd/pim_zebra.c')
| -rw-r--r-- | pimd/pim_zebra.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/pimd/pim_zebra.c b/pimd/pim_zebra.c index 7b060aef4b..a1107e2424 100644 --- a/pimd/pim_zebra.c +++ b/pimd/pim_zebra.c @@ -184,6 +184,13 @@ static int pim_zebra_if_state_up(int command, struct zclient *zclient, && (ifp->vrf_id != vrf->vrf_id)) { struct interface *master = if_lookup_by_name( vrf->name, vrf->vrf_id); + + if (!master) { + zlog_debug("%s: Unable to find Master interface for %s", + __PRETTY_FUNCTION__, + vrf->name); + return 0; + } zclient_interface_set_master(zclient, master, ifp); } |
