From fa60f2c2fac9ff6d71e8bddab92f78a6d558035b Mon Sep 17 00:00:00 2001 From: Fabrice Fontaine Date: Tue, 8 Nov 2022 18:48:41 +0100 Subject: [PATCH] zebra/netconf_netlink.c: fix build without AF_MPLS Fix the following build failure raised since version 8.4 and https://github.com/FRRouting/frr/commit/d53dc9bd8164ba40242e2013d382fb01eb0b96ed: zebra/netconf_netlink.c: In function 'netlink_netconf_change': zebra/netconf_netlink.c:109:32: error: 'AF_MPLS' undeclared (first use in this function) 109 | if (ncm->ncm_family == AF_MPLS) | ^~~~~~~ Signed-off-by: Fabrice Fontaine --- zebra/netconf_netlink.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/zebra/netconf_netlink.c b/zebra/netconf_netlink.c index 56f56bfe66..4c30544e5d 100644 --- a/zebra/netconf_netlink.c +++ b/zebra/netconf_netlink.c @@ -106,9 +106,11 @@ int netlink_netconf_change(struct nlmsghdr *h, ns_id_t ns_id, int startup) * to do a good job of not sending data that is mixed/matched * across families */ +#ifdef AF_MPLS if (ncm->ncm_family == AF_MPLS) afi = AFI_IP; else +#endif /* AF_MPLS */ afi = family2afi(ncm->ncm_family); netlink_parse_rtattr(tb, NETCONFA_MAX, netconf_rta(ncm), len); -- 2.39.5