summaryrefslogtreecommitdiff
path: root/accel-pppd/shaper/limiter.c
diff options
context:
space:
mode:
authorKozlov Dmitry <xeb@mail.ru>2012-03-07 20:23:30 +0400
committerKozlov Dmitry <xeb@mail.ru>2012-03-07 20:23:30 +0400
commitad119336820cb6726a71e61611b616dffa30c1dc (patch)
treef3899cf9a70a2ecabd2e5a55d4b9ef203bcdf781 /accel-pppd/shaper/limiter.c
parentfc8e1ddf2df2e71534f1f2b77dbe5ba6ebf4b745 (diff)
downloadaccel-ppp-ad119336820cb6726a71e61611b616dffa30c1dc.tar.gz
accel-ppp-ad119336820cb6726a71e61611b616dffa30c1dc.zip
shaper: apply cburst value only if it not zero else set it same as burst
Diffstat (limited to 'accel-pppd/shaper/limiter.c')
-rw-r--r--accel-pppd/shaper/limiter.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/accel-pppd/shaper/limiter.c b/accel-pppd/shaper/limiter.c
index 6becb395..f368b331 100644
--- a/accel-pppd/shaper/limiter.c
+++ b/accel-pppd/shaper/limiter.c
@@ -110,7 +110,7 @@ static int qdisc_htb_class(struct qdisc_opt *qopt, struct nlmsghdr *n)
log_ppp_error("shaper: failed to calculate ceil rate table.\n");
return -1;
}
- opt.cbuffer = tc_calc_xmittime(opt.ceil.rate, conf_cburst);
+ opt.cbuffer = tc_calc_xmittime(opt.ceil.rate, conf_cburst ? conf_cburst : qopt->buffer);
tail = NLMSG_TAIL(n);
addattr_l(n, 1024, TCA_OPTIONS, NULL, 0);