From fd996b7dc4464bbfccafaa4ba52246258fc4ae89 Mon Sep 17 00:00:00 2001 From: Dmitry Kozlov Date: Fri, 25 May 2018 12:44:41 +0300 Subject: ifcfg: assign p-t-p address if mask=32 and regular address in other cases --- accel-pppd/libnetlink/iputils.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'accel-pppd/libnetlink/iputils.c') diff --git a/accel-pppd/libnetlink/iputils.c b/accel-pppd/libnetlink/iputils.c index 1f0592c..ad6005f 100644 --- a/accel-pppd/libnetlink/iputils.c +++ b/accel-pppd/libnetlink/iputils.c @@ -359,7 +359,7 @@ int __export ipaddr_add(int ifindex, in_addr_t addr, int mask) return r; } -int __export ipaddr_add_peer(int ifindex, in_addr_t addr, in_addr_t peer_addr, int mask) +int __export ipaddr_add_peer(int ifindex, in_addr_t addr, in_addr_t peer_addr) { struct ipaddr_req { struct nlmsghdr n; @@ -379,7 +379,7 @@ int __export ipaddr_add_peer(int ifindex, in_addr_t addr, in_addr_t peer_addr, i req.n.nlmsg_type = RTM_NEWADDR; req.i.ifa_family = AF_INET; req.i.ifa_index = ifindex; - req.i.ifa_prefixlen = mask; + req.i.ifa_prefixlen = 32; addattr32(&req.n, sizeof(req), IFA_LOCAL, addr); addattr32(&req.n, sizeof(req), IFA_ADDRESS, peer_addr); -- cgit v1.2.3