From mboxrd@z Thu Jan 1 00:00:00 1970 From: Phil Sutter Subject: [iproute PATCH v2 7/7] tc/q_multiq: Don't pass garbage in TCA_OPTIONS Date: Thu, 17 Aug 2017 19:09:31 +0200 Message-ID: <20170817170931.24302-8-phil@nwl.cc> References: <20170817170931.24302-1-phil@nwl.cc> Cc: netdev@vger.kernel.org To: Stephen Hemminger Return-path: Received: from orbyte.nwl.cc ([151.80.46.58]:45289 "EHLO mail.nwl.cc" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752610AbdHQRLa (ORCPT ); Thu, 17 Aug 2017 13:11:30 -0400 In-Reply-To: <20170817170931.24302-1-phil@nwl.cc> Sender: netdev-owner@vger.kernel.org List-ID: multiq_parse_opt() doesn't change 'opt' at all. So at least make sure it doesn't fill TCA_OPTIONS attribute with garbage from stack. Signed-off-by: Phil Sutter --- tc/q_multiq.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tc/q_multiq.c b/tc/q_multiq.c index 7823931494563..9c09c9a7748f6 100644 --- a/tc/q_multiq.c +++ b/tc/q_multiq.c @@ -43,7 +43,7 @@ static void explain(void) static int multiq_parse_opt(struct qdisc_util *qu, int argc, char **argv, struct nlmsghdr *n) { - struct tc_multiq_qopt opt; + struct tc_multiq_qopt opt = {}; if (argc) { if (strcmp(*argv, "help") == 0) { -- 2.13.1