]> git.ipfire.org Git - thirdparty/iptables.git/commitdiff
nft: fix family operation lookup
authorGiuseppe Longo <giuseppelng@gmail.com>
Fri, 26 Jul 2013 11:05:19 +0000 (13:05 +0200)
committerPablo Neira Ayuso <pablo@netfilter.org>
Mon, 30 Dec 2013 22:50:40 +0000 (23:50 +0100)
xtables-restore -6 was using the IPv4 family, instead of IPv6
as it should be.

Signed-off-by: Giuseppe Longo <giuseppelng@gmail.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
iptables/xtables.c

index 3035546667edfe14cb1358db14705816b5da0be3..946f04d62b80de7c4197a62f68980d65c5db7780 100644 (file)
@@ -1110,7 +1110,7 @@ int do_commandx(struct nft_handle *h, int argc, char *argv[], char **table)
        if (h->family == AF_UNSPEC)
                h->family = args.family;
 
-       h->ops = nft_family_ops_lookup(args.family);
+       h->ops = nft_family_ops_lookup(h->family);
        if (h->ops == NULL)
                xtables_error(PARAMETER_PROBLEM, "Unknown family");