diff options
| author | 2006-09-23 21:03:52 -0500 | |
|---|---|---|
| committer | 2006-09-23 21:03:52 -0500 | |
| commit | 1aedf2ccc60fade26c46fae12e28664d0da3f199 (patch) | |
| tree | d91083e3079f1ddb942a382ac2b5a7525570ad59 /net/netfilter/xt_comment.c | |
| parent | [SCSI] SPI transport class: misc DV fixes (diff) | |
| parent | Merge git://git.infradead.org/mtd-2.6 (diff) | |
| download | wireguard-linux-1aedf2ccc60fade26c46fae12e28664d0da3f199.tar.xz wireguard-linux-1aedf2ccc60fade26c46fae12e28664d0da3f199.zip | |
Merge mulgrave-w:git/linux-2.6
Conflicts:
include/linux/blkdev.h
Trivial merge to incorporate tag prototypes.
Diffstat (limited to 'net/netfilter/xt_comment.c')
| -rw-r--r-- | net/netfilter/xt_comment.c | 45 |
1 files changed, 18 insertions, 27 deletions
diff --git a/net/netfilter/xt_comment.c b/net/netfilter/xt_comment.c index 197609cb06d7..7db492d65220 100644 --- a/net/netfilter/xt_comment.c +++ b/net/netfilter/xt_comment.c @@ -29,41 +29,32 @@ match(const struct sk_buff *skb, return 1; } -static struct xt_match comment_match = { - .name = "comment", - .match = match, - .matchsize = sizeof(struct xt_comment_info), - .family = AF_INET, - .me = THIS_MODULE -}; - -static struct xt_match comment6_match = { - .name = "comment", - .match = match, - .matchsize = sizeof(struct xt_comment_info), - .family = AF_INET6, - .me = THIS_MODULE +static struct xt_match xt_comment_match[] = { + { + .name = "comment", + .family = AF_INET, + .match = match, + .matchsize = sizeof(struct xt_comment_info), + .me = THIS_MODULE + }, + { + .name = "comment", + .family = AF_INET6, + .match = match, + .matchsize = sizeof(struct xt_comment_info), + .me = THIS_MODULE + }, }; static int __init xt_comment_init(void) { - int ret; - - ret = xt_register_match(&comment_match); - if (ret) - return ret; - - ret = xt_register_match(&comment6_match); - if (ret) - xt_unregister_match(&comment_match); - - return ret; + return xt_register_matches(xt_comment_match, + ARRAY_SIZE(xt_comment_match)); } static void __exit xt_comment_fini(void) { - xt_unregister_match(&comment_match); - xt_unregister_match(&comment6_match); + xt_unregister_matches(xt_comment_match, ARRAY_SIZE(xt_comment_match)); } module_init(xt_comment_init); |
