]> err.no Git - linux-2.6/blobdiff - net/netfilter/xt_state.c
Merge branch 'e1000-fixes' of git://198.78.49.142/~jbrandeb/linux-2.6
[linux-2.6] / net / netfilter / xt_state.c
index 39ce808d40ef7b834daeb598e3a9935d23e55f12..b8ec00cd51fc1d16b4c04c17dbbbed0e5b57af0b 100644 (file)
@@ -24,6 +24,7 @@ static int
 match(const struct sk_buff *skb,
       const struct net_device *in,
       const struct net_device *out,
+      const struct xt_match *match,
       const void *matchinfo,
       int offset,
       unsigned int protoff,
@@ -43,29 +44,17 @@ match(const struct sk_buff *skb,
        return (sinfo->statemask & statebit);
 }
 
-static int check(const char *tablename,
-                const void *ip,
-                void *matchinfo,
-                unsigned int matchsize,
-                unsigned int hook_mask)
-{
-       if (matchsize != XT_ALIGN(sizeof(struct xt_state_info)))
-               return 0;
-
-       return 1;
-}
-
 static struct xt_match state_match = {
        .name           = "state",
-       .match          = &match,
-       .checkentry     = &check,
+       .match          = match,
+       .matchsize      = sizeof(struct xt_state_info),
        .me             = THIS_MODULE,
 };
 
 static struct xt_match state6_match = {
        .name           = "state",
-       .match          = &match,
-       .checkentry     = &check,
+       .match          = match,
+       .matchsize      = sizeof(struct xt_state_info),
        .me             = THIS_MODULE,
 };