[NETFILTER]: xt_string: fix negation The xt_string match is broken with ! negation. This resolves a portion of netfilter bugzilla #497. Signed-off-by: Phil Oester Signed-off-by: Patrick McHardy --- commit 71c55528be7cf1199376a1b1c5489f60bf2b2617 tree 9a3262f5694c8eb859852981536baa874d3b0fab parent 9f737633e6ee54fc174282d49b2559bd2208391d author Phil Oester Tue, 08 Aug 2006 11:09:06 +0200 committer Patrick McHardy Tue, 08 Aug 2006 11:09:06 +0200 net/netfilter/xt_string.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/net/netfilter/xt_string.c b/net/netfilter/xt_string.c index d8e3891..275330f 100644 --- a/net/netfilter/xt_string.c +++ b/net/netfilter/xt_string.c @@ -37,7 +37,7 @@ static int match(const struct sk_buff *s return (skb_find_text((struct sk_buff *)skb, conf->from_offset, conf->to_offset, conf->config, &state) - != UINT_MAX) && !conf->invert; + != UINT_MAX) ^ conf->invert; } #define STRING_TEXT_PRIV(m) ((struct xt_string_info *) m)