]> git.ipfire.org Git - thirdparty/iproute2.git/commitdiff
link_vti6: Always add local/remote endpoint attributes
authorSerhey Popovych <serhe.popovych@gmail.com>
Mon, 18 Dec 2017 17:48:05 +0000 (19:48 +0200)
committerStephen Hemminger <stephen@networkplumber.org>
Tue, 19 Dec 2017 16:14:59 +0000 (08:14 -0800)
All tunnels already support for parsing/adding zero
endpoints and vti6 isn't an exception.

This check was added as part of commit 2a80154fde40
(vti6: fix local/remote any addr handling) and looks
too restrictive as purpose of change is to avoid
endpoint configuration from uninitialized data.

Signed-off-by: Serhey Popovych <serhe.popovych@gmail.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
ip/link_vti6.c

index f631839aa2d73343378e3706efa8a52cd17e281a..4136b0e7a526aef9147f7417e7d548b14ffac2da 100644 (file)
@@ -154,10 +154,8 @@ get_failed:
        addattr32(n, 1024, IFLA_VTI_IKEY, ikey);
        addattr32(n, 1024, IFLA_VTI_OKEY, okey);
 
-       if (memcmp(&saddr, &in6addr_any, sizeof(in6addr_any)))
-           addattr_l(n, 1024, IFLA_VTI_LOCAL, &saddr, sizeof(saddr));
-       if (memcmp(&daddr, &in6addr_any, sizeof(in6addr_any)))
-           addattr_l(n, 1024, IFLA_VTI_REMOTE, &daddr, sizeof(daddr));
+       addattr_l(n, 1024, IFLA_VTI_LOCAL, &saddr, sizeof(saddr));
+       addattr_l(n, 1024, IFLA_VTI_REMOTE, &daddr, sizeof(daddr));
        addattr32(n, 1024, IFLA_VTI_FWMARK, fwmark);
        if (link)
                addattr32(n, 1024, IFLA_VTI_LINK, link);