summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--zebra/if_netlink.c3
-rw-r--r--zebra/zebra_ptm.c15
2 files changed, 6 insertions, 12 deletions
diff --git a/zebra/if_netlink.c b/zebra/if_netlink.c
index 678c217321..3665ad061d 100644
--- a/zebra/if_netlink.c
+++ b/zebra/if_netlink.c
@@ -465,8 +465,7 @@ netlink_interface_addr (struct sockaddr_nl *snl, struct nlmsghdr *h,
zns = zebra_ns_lookup (ns_id);
ifa = NLMSG_DATA (h);
- if (ifa->ifa_family != AF_INET
- && ifa->ifa_family != AF_INET6)
+ if (ifa->ifa_family != AF_INET && ifa->ifa_family != AF_INET6)
return 0;
if (h->nlmsg_type != RTM_NEWADDR && h->nlmsg_type != RTM_DELADDR)
diff --git a/zebra/zebra_ptm.c b/zebra/zebra_ptm.c
index 194833f1e9..f3f849a6f4 100644
--- a/zebra/zebra_ptm.c
+++ b/zebra/zebra_ptm.c
@@ -891,17 +891,12 @@ zebra_ptm_bfd_dst_deregister (struct zserv *client, int sock, u_short length,
stream_get(&src_p.u.prefix, s, src_p.prefixlen);
if (src_p.family == AF_INET)
- {
- inet_ntop(AF_INET, &src_p.u.prefix4, buf, sizeof(buf));
- ptm_lib_append_msg(ptm_hdl, out_ctxt,
- ZEBRA_PTM_BFD_SRC_IP_FIELD, buf);
- }
+ inet_ntop(AF_INET, &src_p.u.prefix4, buf, sizeof(buf));
else
- {
- inet_ntop(AF_INET6, &src_p.u.prefix6, buf, sizeof(buf));
- ptm_lib_append_msg(ptm_hdl, out_ctxt,
- ZEBRA_PTM_BFD_SRC_IP_FIELD, buf);
- }
+ inet_ntop(AF_INET6, &src_p.u.prefix6, buf, sizeof(buf));
+ ptm_lib_append_msg(ptm_hdl, out_ctxt,
+ ZEBRA_PTM_BFD_SRC_IP_FIELD, buf);
+
if (zvrf_id (zvrf) != VRF_DEFAULT)
ptm_lib_append_msg(ptm_hdl, out_ctxt, ZEBRA_PTM_BFD_VRF_NAME_FIELD,
zvrf_name (zvrf));