ip tunnel parameter parsing fix by Jean Wolter <jw5@os.inf.tu-dresden.de>
authorDenis Vlasenko <vda.linux@googlemail.com>
Wed, 10 Oct 2007 14:43:03 +0000 (14:43 -0000)
committerDenis Vlasenko <vda.linux@googlemail.com>
Wed, 10 Oct 2007 14:43:03 +0000 (14:43 -0000)
networking/libiproute/iptunnel.c

index a936a42755e16f2a2a4a76793e384fd83a90a94f..a45e64d604cb5e8f4159b347d83330c2ab4082f9 100644 (file)
@@ -241,12 +241,12 @@ static void parse_args(int argc, char **argv, int cmd, struct ip_tunnel_parm *p)
                } else if (key == ARG_remote) {
                        NEXT_ARG();
                        key = index_in_strings(keywords, *argv);
-                       if (key == ARG_any)
+                       if (key != ARG_any)
                                p->iph.daddr = get_addr32(*argv);
                } else if (key == ARG_local) {
                        NEXT_ARG();
                        key = index_in_strings(keywords, *argv);
-                       if (key == ARG_any)
+                       if (key != ARG_any)
                                p->iph.saddr = get_addr32(*argv);
                } else if (key == ARG_dev) {
                        NEXT_ARG();