|
|
049c96 |
From d3f086bcbaf690e311df10f867005c2b97231231 Mon Sep 17 00:00:00 2001
|
|
|
049c96 |
From: Jakub Sitnicki <jkbs@redhat.com>
|
|
|
049c96 |
Date: Wed, 27 Jul 2016 15:56:18 +0200
|
|
|
049c96 |
Subject: [PATCH] iplink: Add missing variable initialization
|
|
|
049c96 |
|
|
|
049c96 |
Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1253767
|
|
|
049c96 |
https://bugzilla.redhat.com/show_bug.cgi?id=1271580
|
|
|
049c96 |
Upstream Status: iproute2.git commit a89193a
|
|
|
049c96 |
Conflicts:
|
|
|
049c96 |
* context in iplink_parse_vf() because we don't have
|
|
|
049c96 |
6c5ffb9a2c3d ("iplink: cleanup whitespace and checkpatch issues")
|
|
|
049c96 |
|
|
|
049c96 |
commit a89193a7d68f59c1ce3bf47a32ff7b73661f1c54
|
|
|
049c96 |
Author: Phil Sutter <phil@nwl.cc>
|
|
|
049c96 |
Date: Thu Jun 16 16:19:39 2016 +0200
|
|
|
049c96 |
|
|
|
049c96 |
iplink: Add missing variable initialization
|
|
|
049c96 |
|
|
|
049c96 |
Without this, we might feed garbage to the kernel when the address is
|
|
|
049c96 |
shorter than expected.
|
|
|
049c96 |
|
|
|
049c96 |
Signed-off-by: Phil Sutter <phil@nwl.cc>
|
|
|
049c96 |
---
|
|
|
049c96 |
ip/iplink.c | 2 +-
|
|
|
049c96 |
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
|
049c96 |
|
|
|
049c96 |
diff --git a/ip/iplink.c b/ip/iplink.c
|
|
|
049c96 |
index 461dc95..7b070f4 100644
|
|
|
049c96 |
--- a/ip/iplink.c
|
|
|
049c96 |
+++ b/ip/iplink.c
|
|
|
049c96 |
@@ -268,7 +268,7 @@ static int iplink_parse_vf(int vf, int *argcp, char ***argvp,
|
|
|
049c96 |
while (NEXT_ARG_OK()) {
|
|
|
049c96 |
NEXT_ARG();
|
|
|
049c96 |
if (matches(*argv, "mac") == 0) {
|
|
|
049c96 |
- struct ifla_vf_mac ivm;
|
|
|
049c96 |
+ struct ifla_vf_mac ivm = { 0 };
|
|
|
049c96 |
NEXT_ARG();
|
|
|
049c96 |
ivm.vf = vf;
|
|
|
049c96 |
len = ll_addr_a2n((char *)ivm.mac, 32, *argv);
|
|
|
049c96 |
--
|
|
|
049c96 |
1.8.3.1
|
|
|
049c96 |
|