Merge to Fedora kernel-2.6.18-1.2224_FC5 patched with stable patch-2.6.18.1-vs2.0...
[linux-2.6.git] / net / netfilter / xt_sctp.c
index c29692c..843383e 100644 (file)
@@ -129,11 +129,9 @@ match(const struct sk_buff *skb,
       unsigned int protoff,
       int *hotdrop)
 {
-       const struct xt_sctp_info *info;
+       const struct xt_sctp_info *info = matchinfo;
        sctp_sctphdr_t _sh, *sh;
 
-       info = (const struct xt_sctp_info *)matchinfo;
-
        if (offset) {
                duprintf("Dropping non-first fragment.. FIXME\n");
                return 0;
@@ -153,7 +151,7 @@ match(const struct sk_buff *skb,
                && SCCHECK(((ntohs(sh->dest) >= info->dpts[0]) 
                        && (ntohs(sh->dest) <= info->dpts[1])), 
                        XT_SCTP_DEST_PORTS, info->flags, info->invflags)
-               && SCCHECK(match_packet(skb, protoff,
+               && SCCHECK(match_packet(skb, protoff + sizeof (sctp_sctphdr_t),
                                        info->chunkmap, info->chunk_match_type,
                                        info->flag_info, info->flag_count, 
                                        hotdrop),