#include "zebra/zebra_mpls.h"
#include "zebra/debug.h"
#include "zebra/zebra_errors.h"
+#include "zebra/zebra_router.h"
#include "privs.h"
#include "prefix.h"
hdr.rtm_mpls = MPLS_OP_SWAP;
}
- frr_elevate_privs(&zserv_privs) {
+ frr_with_privs(&zserv_privs) {
ret = writev(kr_state.fd, iov, iovcnt);
}
hdr.rtm_mpls = MPLS_OP_SWAP;
}
- frr_elevate_privs(&zserv_privs) {
+ frr_with_privs(&zserv_privs) {
ret = writev(kr_state.fd, iov, iovcnt);
}
if (!nexthop)
continue;
- if (nexthop_num >= multipath_num)
+ if (nexthop_num >= zrouter.multipath_num)
break;
if (((action == RTM_ADD || action == RTM_CHANGE)
}
}
- return (0);
+ return 0;
}
enum zebra_dplane_result kernel_lsp_update(struct zebra_dplane_ctx *ctx)
/* ioctl */
memset(&ifr, 0, sizeof(ifr));
- strlcpy(ifr.ifr_name, dplane_ctx_get_pw_ifname(ctx),
+ strlcpy(ifr.ifr_name, dplane_ctx_get_ifname(ctx),
sizeof(ifr.ifr_name));
ifr.ifr_data = (caddr_t)&imr;
if (ioctl(kr_state.ioctl_fd, SIOCSETMPWCFG, &ifr) == -1) {
memset(&ifr, 0, sizeof(ifr));
memset(&imr, 0, sizeof(imr));
- strlcpy(ifr.ifr_name, dplane_ctx_get_pw_ifname(ctx),
+ strlcpy(ifr.ifr_name, dplane_ctx_get_ifname(ctx),
sizeof(ifr.ifr_name));
ifr.ifr_data = (caddr_t)&imr;
if (ioctl(kr_state.ioctl_fd, SIOCSETMPWCFG, &ifr) == -1) {