summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFabrice Fontaine <fontaine.fabrice@gmail.com>2022-11-08 18:48:41 +0100
committerMergify <37929162+mergify[bot]@users.noreply.github.com>2022-11-09 05:25:17 +0000
commiteed83c07cc2c08d1b7eb33effa396d4732b20dc1 (patch)
tree4b68648603e54cfb432772b54164d10bce958cc0
parentbf74460ce359c430ac1368bc54e46e2258e733d2 (diff)
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 <fontaine.fabrice@gmail.com> (cherry picked from commit fa60f2c2fac9ff6d71e8bddab92f78a6d558035b)
-rw-r--r--zebra/netconf_netlink.c2
1 files changed, 2 insertions, 0 deletions
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);