tree 59a340d83e8381a249e379b70a26729fb8482825
parent a5ea169c9581553662bb79a1c8c98fed1ee84246
author Patrick McHardy <[EMAIL PROTECTED]> Sun, 21 Aug 2005 07:38:40 -0700
committer David S. Miller <[EMAIL PROTECTED]> Sun, 21 Aug 2005 07:38:40 -0700

[NETFILTER]: Fix ECN target TCP marking

An incorrect check made it bail out before doing anything.

Signed-off-by: Patrick McHardy <[EMAIL PROTECTED]>
Signed-off-by: David S. Miller <[EMAIL PROTECTED]>

 net/ipv4/netfilter/ipt_ECN.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/net/ipv4/netfilter/ipt_ECN.c b/net/ipv4/netfilter/ipt_ECN.c
--- a/net/ipv4/netfilter/ipt_ECN.c
+++ b/net/ipv4/netfilter/ipt_ECN.c
@@ -61,10 +61,10 @@ set_ect_tcp(struct sk_buff **pskb, const
        if (!tcph)
                return 0;
 
-       if (!(einfo->operation & IPT_ECN_OP_SET_ECE
-             || tcph->ece == einfo->proto.tcp.ece)
-           && (!(einfo->operation & IPT_ECN_OP_SET_CWR
-                 || tcph->cwr == einfo->proto.tcp.cwr)))
+       if ((!(einfo->operation & IPT_ECN_OP_SET_ECE) ||
+            tcph->ece == einfo->proto.tcp.ece) &&
+           ((!(einfo->operation & IPT_ECN_OP_SET_CWR) ||
+            tcph->cwr == einfo->proto.tcp.cwr)))
                return 1;
 
        if (!skb_ip_make_writable(pskb, (*pskb)->nh.iph->ihl*4+sizeof(*tcph)))
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to