summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDmitry Kozlov <xeb@mail.ru>2018-02-05 21:29:47 +0300
committerDmitry Kozlov <xeb@mail.ru>2018-02-05 21:29:47 +0300
commit54f225b10ddd13ad4a7e3e5359fdbd2bf927d130 (patch)
tree39754e51589308c87f52ab1241580f4973288829
parent8e1e3e913868390334fddc71a903cc48ec17e296 (diff)
downloadaccel-ppp-54f225b10ddd13ad4a7e3e5359fdbd2bf927d130.tar.gz
accel-ppp-54f225b10ddd13ad4a7e3e5359fdbd2bf927d130.zip
pppd_compat: call ip-down even if ip-up is not specified
-rw-r--r--accel-pppd/extra/pppd_compat.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/accel-pppd/extra/pppd_compat.c b/accel-pppd/extra/pppd_compat.c
index 8a4f3ac..2db2440 100644
--- a/accel-pppd/extra/pppd_compat.c
+++ b/accel-pppd/extra/pppd_compat.c
@@ -286,12 +286,13 @@ static void ev_ses_started(struct ap_session *ses)
char peer_ipaddr[17];
struct pppd_compat_pd *pd;
- if (!conf_ip_up)
+ pd = find_pd(ses);
+ if (!pd)
return;
- pd = find_pd(ses);
+ pd->started = 1;
- if (!pd)
+ if (!conf_ip_up)
return;
argv[4] = ipaddr;
@@ -320,8 +321,6 @@ static void ev_ses_started(struct ap_session *ses)
_exit(EXIT_FAILURE);
} else
log_error("pppd_compat: fork: %s\n", strerror(errno));
-
- pd->started = 1;
}
static void ev_ses_finished(struct ap_session *ses)