naccyde / rpms / iproute

Forked from rpms/iproute 10 months ago
Clone

Blame SOURCES/0096-tc-q_multiq-Don-t-pass-garbage-in-TCA_OPTIONS.patch

36cfb7
From 8a115584261b32308d604063b56f25330ce8adaf Mon Sep 17 00:00:00 2001
36cfb7
From: Andrea Claudi <aclaudi@redhat.com>
36cfb7
Date: Mon, 29 Apr 2019 20:08:07 +0200
36cfb7
Subject: [PATCH] tc/q_multiq: Don't pass garbage in TCA_OPTIONS
36cfb7
36cfb7
Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1465646
36cfb7
Upstream Status: iproute2.git commit 82ed9ffa2bb86
36cfb7
36cfb7
commit 82ed9ffa2bb86eea653f68a0ade945b7708818c9
36cfb7
Author: Phil Sutter <phil@nwl.cc>
36cfb7
Date:   Mon Aug 21 11:27:04 2017 +0200
36cfb7
36cfb7
    tc/q_multiq: Don't pass garbage in TCA_OPTIONS
36cfb7
36cfb7
    multiq_parse_opt() doesn't change 'opt' at all. So at least make sure
36cfb7
    it doesn't fill TCA_OPTIONS attribute with garbage from stack.
36cfb7
36cfb7
    Signed-off-by: Phil Sutter <phil@nwl.cc>
36cfb7
---
36cfb7
 tc/q_multiq.c | 2 +-
36cfb7
 1 file changed, 1 insertion(+), 1 deletion(-)
36cfb7
36cfb7
diff --git a/tc/q_multiq.c b/tc/q_multiq.c
36cfb7
index 7823931494563..9c09c9a7748f6 100644
36cfb7
--- a/tc/q_multiq.c
36cfb7
+++ b/tc/q_multiq.c
36cfb7
@@ -43,7 +43,7 @@ static void explain(void)
36cfb7
 static int multiq_parse_opt(struct qdisc_util *qu, int argc, char **argv,
36cfb7
 			    struct nlmsghdr *n)
36cfb7
 {
36cfb7
-	struct tc_multiq_qopt opt;
36cfb7
+	struct tc_multiq_qopt opt = {};
36cfb7
 
36cfb7
 	if (argc) {
36cfb7
 		if (strcmp(*argv, "help") == 0) {
36cfb7
-- 
36cfb7
2.20.1
36cfb7