iplink: Add missing variable initialization

Without this, we might feed garbage to the kernel when the address is
shorter than expected.

Signed-off-by: Phil Sutter <phil@nwl.cc>
This commit is contained in:
Phil Sutter 2016-06-16 16:19:39 +02:00 committed by Stephen Hemminger
parent 414aeec90f
commit a89193a7d6
1 changed files with 1 additions and 1 deletions

View File

@ -273,7 +273,7 @@ static int iplink_parse_vf(int vf, int *argcp, char ***argvp,
while (NEXT_ARG_OK()) {
NEXT_ARG();
if (matches(*argv, "mac") == 0) {
struct ifla_vf_mac ivm;
struct ifla_vf_mac ivm = { 0 };
NEXT_ARG();
ivm.vf = vf;