]> git.ipfire.org Git - thirdparty/iptables.git/commitdiff
extensions: DNAT: Fix bad IP address error reporting
authorPhil Sutter <phil@nwl.cc>
Sun, 3 Jul 2022 13:59:19 +0000 (15:59 +0200)
committerPhil Sutter <phil@nwl.cc>
Fri, 11 Nov 2022 18:13:10 +0000 (19:13 +0100)
When introducing 'start' variable to cover for IPv6 addresses enclosed
in brackets, this single spot was missed.

Fixes: 14d77c8aa29a7 ("extensions: Merge IPv4 and IPv6 DNAT targets")
Signed-off-by: Phil Sutter <phil@nwl.cc>
extensions/libxt_DNAT.c

index 5696d31f2b0c5a7ed99c8018af2aa580827dc673..7bfefc7961fac68898bb8c81d4f9fa2d8ebe28c5 100644 (file)
@@ -197,7 +197,7 @@ parse_to(const char *orig_arg, bool portok,
 
        if (!inet_pton(family, start, &range->min_addr))
                xtables_error(PARAMETER_PROBLEM,
-                             "Bad IP address \"%s\"", arg);
+                             "Bad IP address \"%s\"", start);
        if (dash) {
                if (!inet_pton(family, dash + 1, &range->max_addr))
                        xtables_error(PARAMETER_PROBLEM,