From d5c3630d92b329735048b228878bb3ae137799cc Mon Sep 17 00:00:00 2001 From: Dmitry Kozlov Date: Sun, 18 May 2014 01:04:19 +0000 Subject: improved single-session=replace handling Wait for previous session completely terminated before continuing authorization new session. --- accel-pppd/ppp/ppp_auth.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'accel-pppd/ppp') diff --git a/accel-pppd/ppp/ppp_auth.c b/accel-pppd/ppp/ppp_auth.c index 0510358c..b32400e2 100644 --- a/accel-pppd/ppp/ppp_auth.c +++ b/accel-pppd/ppp/ppp_auth.c @@ -336,10 +336,10 @@ int __export ppp_auth_succeeded(struct ppp_t *ppp, char *username) { struct auth_layer_data_t *ad = container_of(ppp_find_layer_data(ppp, &auth_layer), typeof(*ad), ld); - if (ap_session_check_single(username)) + if (ap_session_set_username(&ppp->ses, username)) { + _free(username); return -1; - - ppp->ses.username = username; + } triton_context_call(ppp->ses.ctrl->ctx, (triton_event_func)__ppp_auth_started, ppp); -- cgit v1.2.3