summaryrefslogtreecommitdiff
path: root/accel-pppd/ctrl
diff options
context:
space:
mode:
authorDmitry Kozlov <xeb@mail.ru>2018-05-25 12:46:11 +0300
committerDmitry Kozlov <xeb@mail.ru>2018-05-25 12:46:11 +0300
commitacc53d157ba6b69ca038e6d21be60ce75334f477 (patch)
tree2ab9443d199a6660b4beb3a31a5b55d1d72267d8 /accel-pppd/ctrl
parentfd996b7dc4464bbfccafaa4ba52246258fc4ae89 (diff)
downloadaccel-ppp-acc53d157ba6b69ca038e6d21be60ce75334f477.tar.gz
accel-ppp-acc53d157ba6b69ca038e6d21be60ce75334f477.zip
ipoe: do not remove address on session finish if ifcfg=1
Diffstat (limited to 'accel-pppd/ctrl')
-rw-r--r--accel-pppd/ctrl/ipoe/ipoe.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/accel-pppd/ctrl/ipoe/ipoe.c b/accel-pppd/ctrl/ipoe/ipoe.c
index f5a00ca..acfc62c 100644
--- a/accel-pppd/ctrl/ipoe/ipoe.c
+++ b/accel-pppd/ctrl/ipoe/ipoe.c
@@ -1164,12 +1164,12 @@ static void ipoe_session_finished(struct ap_session *s)
} else
ipoe_nl_delete(ses->ifindex);
} else if (ses->started) {
- if (serv->opt_ifcfg)
- ipaddr_del(serv->ifindex, ses->router, conf_ip_unnumbered ? 32 : ses->mask);
- else if (conf_ip_unnumbered)
- iproute_del(serv->ifindex, ses->yiaddr, conf_proto, 32, 0);
- else
- iproute_del(serv->ifindex, ses->yiaddr, conf_proto, ses->mask, 0);
+ if (!serv->opt_ifcfg) {
+ if (conf_ip_unnumbered)
+ iproute_del(serv->ifindex, ses->yiaddr, conf_proto, 32, 0);
+ else
+ iproute_del(serv->ifindex, ses->yiaddr, conf_proto, ses->mask, 0);
+ }
}
if (ses->dhcp_addr)