]> git.ipfire.org Git - thirdparty/iptables.git/commitdiff
extensions: libebt_redirect: Fix xlate return code
authorPhil Sutter <phil@nwl.cc>
Wed, 16 Nov 2022 12:03:05 +0000 (13:03 +0100)
committerPhil Sutter <phil@nwl.cc>
Thu, 24 Nov 2022 09:24:06 +0000 (10:24 +0100)
The callback is supposed to return 1 on success, not 0.

Fixes: 24ce7465056ae ("ebtables-compat: add redirect match extension")
Signed-off-by: Phil Sutter <phil@nwl.cc>
extensions/libebt_redirect.c

index 6e653997ee99ec6e585945baab65472eb3487a60..4d4c7a02cea890658bb9585b5b62dd9e3b1e8887 100644 (file)
@@ -86,7 +86,7 @@ static int brredir_xlate(struct xt_xlate *xl,
        xt_xlate_add(xl, "meta set pkttype host");
        if (red->target != EBT_ACCEPT)
                xt_xlate_add(xl, " %s ", brredir_verdict(red->target));
-       return 0;
+       return 1;
 }
 
 static struct xtables_target brredirect_target = {