From f307c24e2fa521616db1a0f83774749744c31dd3 Mon Sep 17 00:00:00 2001 From: "osdl.net!shemminger" Date: Mon, 23 Aug 2004 20:21:21 +0000 Subject: [PATCH] Auto merged 2004/08/11 14:27:34-07:00 osdl.net!shemminger Increase size of netlink buffer. (Logical change 1.71) --- tc/tc_common.h | 3 +++ tc/tc_qdisc.c | 10 +++++----- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/tc/tc_common.h b/tc/tc_common.h index e19a867e..82f59e86 100644 --- a/tc/tc_common.h +++ b/tc/tc_common.h @@ -1,3 +1,6 @@ + +#define TCA_BUF_MAX (64*1024) + extern int do_qdisc(int argc, char **argv); extern int do_class(int argc, char **argv); extern int do_filter(int argc, char **argv); diff --git a/tc/tc_qdisc.c b/tc/tc_qdisc.c index 1a244a87..eb451a47 100644 --- a/tc/tc_qdisc.c +++ b/tc/tc_qdisc.c @@ -44,15 +44,15 @@ static void usage(void) int tc_qdisc_modify(int cmd, unsigned flags, int argc, char **argv) { struct rtnl_handle rth; - struct { - struct nlmsghdr n; - struct tcmsg t; - char buf[4096]; - } req; struct qdisc_util *q = NULL; struct tc_estimator est; char d[16]; char k[16]; + struct { + struct nlmsghdr n; + struct tcmsg t; + char buf[TCA_BUF_MAX]; + } req; memset(&req, 0, sizeof(req)); memset(&est, 0, sizeof(est));