]> git.ipfire.org Git - thirdparty/iptables.git/commitdiff
libxt_dccp: fix deprecated intrapositional ordering of !
authorJan Engelhardt <jengelh@medozas.de>
Sun, 21 Aug 2011 07:08:04 +0000 (09:08 +0200)
committerJan Engelhardt <jengelh@medozas.de>
Sun, 21 Aug 2011 07:37:40 +0000 (09:37 +0200)
This bug goes back to v1.4.3~63.

References: Dave Täht via netfilter-devel on 2011-08-20 14:40:11 -0700
References: <CAA93jw6mpDL6rLXM+9SpAhafkDdKoSfhAxU8UM87vUqjuzjYJw@mail.gmail.com>
Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
extensions/libxt_dccp.c

index 0fc5f7d7d46179f149b517a990ff5f5ca3dafc7b..4de07cca2bbc8ce848232dceb4ac929af0a804f6 100644 (file)
@@ -262,13 +262,14 @@ static void dccp_save(const void *ip, const struct xt_entry_match *match)
        }
 
        if (einfo->flags & XT_DCCP_TYPE) {
-               printf(" --dccp-type");
-               print_types(einfo->typemask, einfo->invflags & XT_DCCP_TYPE,0);
+               printf("%s --dccp-type",
+                      einfo->invflags & XT_DCCP_TYPE ? " !" : "");
+               print_types(einfo->typemask, false, 0);
        }
 
        if (einfo->flags & XT_DCCP_OPTION) {
-               printf(" --dccp-option %s%u",
-                       einfo->typemask & XT_DCCP_OPTION ? "" : "",
+               printf("%s --dccp-option %u",
+                       einfo->typemask & XT_DCCP_OPTION ? " !" : "",
                        einfo->option);
        }
 }