summaryrefslogtreecommitdiff
path: root/accel-pppd/radius/radius.c
diff options
context:
space:
mode:
authorDmitry Kozlov <xeb@mail.ru>2011-01-10 22:28:34 +0300
committerDmitry Kozlov <xeb@mail.ru>2011-01-10 22:28:34 +0300
commit83537ad5c8839c6c006c4a8d5f5b0405f7ac3dae (patch)
treee60e599e366c1e50f6f175dab93b316bf9674033 /accel-pppd/radius/radius.c
parent57ec76a3e15006c94e579662ce710bfd3f032331 (diff)
downloadaccel-ppp-83537ad5c8839c6c006c4a8d5f5b0405f7ac3dae.tar.gz
accel-ppp-83537ad5c8839c6c006c4a8d5f5b0405f7ac3dae.zip
radius: don't send interim-update if time to session timeout is less than 10 s.
Diffstat (limited to 'accel-pppd/radius/radius.c')
-rw-r--r--accel-pppd/radius/radius.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/accel-pppd/radius/radius.c b/accel-pppd/radius/radius.c
index 8976a33..04de1b7 100644
--- a/accel-pppd/radius/radius.c
+++ b/accel-pppd/radius/radius.c
@@ -88,7 +88,7 @@ int rad_proc_attrs(struct rad_req_t *req)
req->rpd->acct_interim_interval = attr->val.integer;
break;
case Session_Timeout:
- req->rpd->session_timeout.period = attr->val.integer * 1000;
+ req->rpd->session_timeout.expire_tv.tv_sec = attr->val.integer;
break;
case Class:
if (!req->rpd->attr_class)
@@ -198,7 +198,7 @@ static void ppp_acct_start(struct ppp_t *ppp)
return;
}
- if (rpd->session_timeout.period) {
+ if (rpd->session_timeout.expire_tv.tv_sec) {
rpd->session_timeout.expire = session_timeout;
triton_timer_add(ppp->ctrl->ctx, &rpd->session_timeout, 0);
}