]> git.ipfire.org Git - thirdparty/iptables.git/commitdiff
Pablo Neira: extensions conversion to C99 structure initialization
authorPablo Neira <pablo@eurodev.net>
Tue, 28 Dec 2004 13:11:59 +0000 (13:11 +0000)
committerRusty Russell <rusty@rustcorp.com.au>
Tue, 28 Dec 2004 13:11:59 +0000 (13:11 +0000)
(I removed the revision stuff for the moment, but this needs to go in before the code moves too much --RR)

69 files changed:
extensions/libipt_BALANCE.c
extensions/libipt_CLASSIFY.c
extensions/libipt_CLUSTERIP.c
extensions/libipt_DNAT.c
extensions/libipt_DSCP.c
extensions/libipt_ECN.c
extensions/libipt_FTOS.c
extensions/libipt_IPMARK.c
extensions/libipt_IPV4OPTSSTRIP.c
extensions/libipt_MARK.c
extensions/libipt_MASQUERADE.c
extensions/libipt_MIRROR.c
extensions/libipt_NETLINK.c
extensions/libipt_NETMAP.c
extensions/libipt_POOL.c
extensions/libipt_REDIRECT.c
extensions/libipt_REJECT.c
extensions/libipt_ROUTE.c
extensions/libipt_SAME.c
extensions/libipt_SNAT.c
extensions/libipt_TARPIT.c
extensions/libipt_TCPMSS.c
extensions/libipt_TOS.c
extensions/libipt_TTL.c
extensions/libipt_ULOG.c
extensions/libipt_XOR.c
extensions/libipt_addrtype.c
extensions/libipt_ah.c
extensions/libipt_comment.c
extensions/libipt_condition.c
extensions/libipt_connbytes.c
extensions/libipt_connlimit.c
extensions/libipt_connrate.c
extensions/libipt_conntrack.c
extensions/libipt_dscp.c
extensions/libipt_dstlimit.c
extensions/libipt_esp.c
extensions/libipt_fuzzy.c
extensions/libipt_hashlimit.c
extensions/libipt_helper.c
extensions/libipt_icmp.c
extensions/libipt_iprange.c
extensions/libipt_ipv4options.c
extensions/libipt_length.c
extensions/libipt_limit.c
extensions/libipt_mac.c
extensions/libipt_mark.c
extensions/libipt_mport.c
extensions/libipt_multiport.c
extensions/libipt_nth.c
extensions/libipt_owner.c
extensions/libipt_physdev.c
extensions/libipt_pkttype.c
extensions/libipt_pool.c
extensions/libipt_psd.c
extensions/libipt_quota.c
extensions/libipt_random.c
extensions/libipt_realm.c
extensions/libipt_rpc.c
extensions/libipt_standard.c
extensions/libipt_state.c
extensions/libipt_tcp.c
extensions/libipt_tcpmss.c
extensions/libipt_time.c
extensions/libipt_tos.c
extensions/libipt_ttl.c
extensions/libipt_u32.c
extensions/libipt_udp.c
extensions/libipt_unclean.c

index 7f0b91698ea00a148f9b95edc118fc03f0daddb9..1b97ea2e80d361d7a3afa2be286f0317eff301ab 100644 (file)
@@ -131,20 +131,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_target *target)
        printf("-%s ", addr_to_dotted(&a));
 }
 
-static
-struct iptables_target balance
-= { NULL,
-    "BALANCE",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ip_nat_multi_range)),
-    IPT_ALIGN(sizeof(struct ip_nat_multi_range)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_target balance = { 
+       .next           = NULL,
+       .name           = "BALANCE",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ip_nat_multi_range)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ip_nat_multi_range)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index ac14b7621963e53d1d8413550e4fa254a55b7b96..16c805399f494cff98f5f6b9e87f9e048534e8b6 100644 (file)
@@ -108,20 +108,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_target *target)
               TC_H_MAJ(clinfo->priority)>>16, TC_H_MIN(clinfo->priority));
 }
 
-static
-struct iptables_target classify
-= { NULL,
-    "CLASSIFY",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_classify_target_info)),
-    IPT_ALIGN(sizeof(struct ipt_classify_target_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_target classify = { 
+       .next           = NULL,
+       .name           = "CLASSIFY",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_classify_target_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_classify_target_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 55e86c5ccab6689f1d7e2a4d1e5a246073d41be4..8b36430570b3eb00749580ad479d6af1b4cc9b82 100644 (file)
@@ -237,20 +237,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_target *target)
        */
 }
 
-static
-struct iptables_target clusterip
-= { NULL,
-    "CLUSTERIP",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_clusterip_tgt_info)),
-    IPT_ALIGN(sizeof(struct ipt_clusterip_tgt_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_target clusterip = { 
+       .next           = NULL,
+       .name           = "CLUSTERIP",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_clusterip_tgt_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_clusterip_tgt_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 9b826758d7b3964d37afc9c323869d49602ab554..d8efa586abe3e7b4b6c15179c59297ef6fd5b86d 100644 (file)
@@ -224,20 +224,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_target *target)
        }
 }
 
-static
-struct iptables_target dnat
-= { NULL,
-    "DNAT",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ip_nat_multi_range)),
-    IPT_ALIGN(sizeof(struct ip_nat_multi_range)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_target dnat = { 
+       .next           = NULL,
+       .name           = "DNAT",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ip_nat_multi_range)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ip_nat_multi_range)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 98a433312a8b8568e0442319444edf6a089039c2..90e2a344067ed5d1e3b8f2af0dcc2b46ffb1dfe7 100644 (file)
@@ -143,20 +143,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_target *target)
        printf("--set-dscp 0x%02x ", dinfo->dscp);
 }
 
-static
-struct iptables_target dscp
-= { NULL,
-    "DSCP",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_DSCP_info)),
-    IPT_ALIGN(sizeof(struct ipt_DSCP_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_target dscp = { 
+       .next           = NULL,
+       .name           = "DSCP",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_DSCP_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_DSCP_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 3f7afbe3f3097a8ad550d2201bf599d39832169f..b9ef29ea460ecf8bcd51e6c2da8b08d6a3344dd4 100644 (file)
@@ -6,7 +6,7 @@
  *
  * libipt_ECN.c borrowed heavily from libipt_DSCP.c
  *
- * $Id: libipt_ECN.c,v 1.11 2002/08/07 10:04:42 laforge Exp $
+ * $Id$
  */
 #include <stdio.h>
 #include <string.h>
@@ -164,19 +164,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_target *target)
 }
 
 static
-struct iptables_target ecn
-= { NULL,
-    "ECN",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_ECN_info)),
-    IPT_ALIGN(sizeof(struct ipt_ECN_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+struct iptables_target ecn = { 
+       .next           = NULL,
+       .name           = "ECN",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_ECN_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_ECN_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 3ff2d5aad257884213f3505edecf46b41355e59c..62df4cdef5532e2bb9a9aa743026d9bdf881ce84 100644 (file)
@@ -112,20 +112,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_target *target)
        printf("--set-ftos 0x%02x ", finfo->ftos);
 }
 
-static
-struct iptables_target ftos
-= { NULL,
-    "FTOS",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_FTOS_info)),
-    IPT_ALIGN(sizeof(struct ipt_FTOS_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_target ftos = {
+       .next           = NULL,
+       .name           = "FTOS",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_FTOS_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_FTOS_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index ae335c44a913087b56825f64ff19ffe787ab2224..3a557fe7b751c9c4f3faa613b42f2eaaa7982e52 100644 (file)
@@ -148,20 +148,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_target *target)
          printf("--or-mask 0x%lx ", ipmarkinfo->ormask);
 }
 
-static
-struct iptables_target ipmark
-= { NULL,
-    "IPMARK",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_ipmark_target_info)),
-    IPT_ALIGN(sizeof(struct ipt_ipmark_target_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_target ipmark = { 
+       .next           = NULL,
+       .name           = "IPMARK",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_ipmark_target_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_ipmark_target_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index f1dcec06a70924b37e44f649426dba7833871823..c154ef53b35b016a136bf84563db1d5c2bb3edaf 100644 (file)
@@ -59,20 +59,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_target *target)
        /* nothing to print, we don't take option... */
 }
 
-static
-struct iptables_target IPV4OPTSSTRIP
-= { NULL,
-    "IPV4OPTSSTRIP",
-    IPTABLES_VERSION,
-    IPT_ALIGN(0),
-    IPT_ALIGN(0),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_target IPV4OPTSSTRIP = { 
+       .next           = NULL,
+       .name           = "IPV4OPTSSTRIP",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(0),
+       .userspacesize  = IPT_ALIGN(0),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 56b09f57098faf4bac731d1683902f1f898bfe78..bc3dd42ef9b62a97ce59601188f86191c5e3b259 100644 (file)
@@ -110,19 +110,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_target *target)
 }
 
 static
-struct iptables_target mark
-= { NULL,
-    "MARK",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_mark_target_info)),
-    IPT_ALIGN(sizeof(struct ipt_mark_target_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+struct iptables_target mark = {
+       .next           = NULL,
+       .name           = "MARK",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_mark_target_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_mark_target_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index c30e2fafc55475ca3655ee40a64e42af70b797ec..31af120342da2bf8ede735bc7ff191710208eef5 100644 (file)
@@ -146,20 +146,18 @@ save(const struct ipt_ip *ip, const struct ipt_entry_target *target)
        }
 }
 
-static
-struct iptables_target masq
-= { NULL,
-    "MASQUERADE",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ip_nat_multi_range)),
-    IPT_ALIGN(sizeof(struct ip_nat_multi_range)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_target masq = { NULL,
+       .name           = "MASQUERADE",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ip_nat_multi_range)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ip_nat_multi_range)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index b5996fa72a7410ce17b2545b7c2d941ded6be720..7e617030aa6f4a453de1a163c6bc301eb5df3671 100644 (file)
@@ -41,20 +41,19 @@ final_check(unsigned int flags)
 {
 }
 
-static
-struct iptables_target mirror
-= { NULL,
-    "MIRROR",
-    IPTABLES_VERSION,
-    IPT_ALIGN(0),
-    IPT_ALIGN(0),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    NULL, /* print */
-    NULL, /* save */
-    opts
+static struct iptables_target mirror = {
+       .next           = NULL,
+       .name           = "MIRROR",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(0),
+       .userspacesize  = IPT_ALIGN(0),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = NULL,
+       .save           = NULL,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 9e71990365880beacc050dc70502c53706132e38..9cc190c2f36cd70d38e673c7f63bd15a8eb8d0ac 100644 (file)
@@ -136,19 +136,19 @@ print(const struct ipt_ip *ip,
                printf("nlsize %i ", nld->size);
 }
 
-static
-struct iptables_target netlink = { NULL,
-       "NETLINK",
-       IPTABLES_VERSION,
-       IPT_ALIGN(sizeof(struct ipt_nldata)),
-       IPT_ALIGN(sizeof(struct ipt_nldata)),
-       &help,
-       &init,
-       &parse,
-       &final_check,
-       &print,
-       &save,
-       opts
+static struct iptables_target netlink = {
+       .next           = NULL,
+       .name           = "NETLINK",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_nldata)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_nldata)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index a45acb90015f8ff3d6317865a108536d767b8ef0..81d0e5c6a96f5b5a215c9acd2f55bcb32f6cab7e 100644 (file)
@@ -179,20 +179,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_target *target)
        print(ip, target, 0);
 }
 
-static
-struct iptables_target target_module
-= { NULL,
-    MODULENAME,
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ip_nat_multi_range)),
-    IPT_ALIGN(sizeof(struct ip_nat_multi_range)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_target target_module = {
+       .next           = NULL,
+       .name           = MODULENAME,
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ip_nat_multi_range)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ip_nat_multi_range)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 931dcfdbece4c8fcf44224ea14166217c7fed1ca..0ce9f20940bc26bb0c03ded3eb68b560dffcad5c 100644 (file)
@@ -133,20 +133,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_target *target)
        }
 }
 
-static
-struct iptables_target ipt_pool_target
-= { NULL,
-    "POOL",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_pool_info)),
-    IPT_ALIGN(sizeof(struct ipt_pool_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_target ipt_pool_target = { 
+       .next           = NULL,
+       .name           = "POOL",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_pool_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_pool_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 052b533c4e5c43b19cfe85a30683017297ab0ba9..b40cb496f627487daa853247f8fee3204afb99a6 100644 (file)
@@ -147,20 +147,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_target *target)
        }
 }
 
-static
-struct iptables_target redir
-= { NULL,
-    "REDIRECT",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ip_nat_multi_range)),
-    IPT_ALIGN(sizeof(struct ip_nat_multi_range)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_target redir = { 
+       .next           = NULL,
+       .name           = "REDIRECT",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ip_nat_multi_range)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ip_nat_multi_range)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 8170edd806b88b98c8f09e10c67b5e28d66b8928..4b08e4531df038beedd24b368e3add0df3cd11bc 100644 (file)
@@ -170,20 +170,19 @@ static void save(const struct ipt_ip *ip, const struct ipt_entry_target *target)
        printf("--reject-with %s ", reject_table[i].name);
 }
 
-static
-struct iptables_target reject
-= { NULL,
-    "REJECT",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_reject_info)),
-    IPT_ALIGN(sizeof(struct ipt_reject_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_target reject = { 
+       .next           = NULL,
+       .name           = "REJECT",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_reject_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_reject_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index b14abdbe2c9f8542ca90f2b33612a0e0a0c416d4..360f9832b6742404c3cd7b11cd5062fea3c754c1 100644 (file)
@@ -243,20 +243,19 @@ static void save(const struct ipt_ip *ip,
 }
 
 
-static
-struct iptables_target route
-= { NULL,
-    "ROUTE",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_route_target_info)),
-    IPT_ALIGN(sizeof(struct ipt_route_target_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_target route = { 
+       .next           = NULL,
+       .name           = "ROUTE",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_route_target_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_route_target_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 52a7e728ef3074c62f0a52e62189846b32f5617d..654550173f2407e0c6f61c69b85c79a1c2371ead 100644 (file)
@@ -189,20 +189,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_target *target)
                printf("--nodst ");
 }
 
-static
-struct iptables_target same
-= { NULL,
-    "SAME",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_same_info)),
-    IPT_ALIGN(sizeof(struct ipt_same_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_target same = {
+       .next           = NULL,
+       .name           = "SAME",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_same_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_same_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index d909c2a18d6f111ecb25e66fd3c9c2ccdb0e7aa6..aca4a813ad6bd62847131e9ba1d7d8262f463e9d 100644 (file)
@@ -224,20 +224,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_target *target)
        }
 }
 
-static
-struct iptables_target snat
-= { NULL,
-    "SNAT",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ip_nat_multi_range)),
-    IPT_ALIGN(sizeof(struct ip_nat_multi_range)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_target snat = {
+       .next           = NULL,
+       .name           = "SNAT",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ip_nat_multi_range)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ip_nat_multi_range)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 643ce6149826ff64a5d691fd8eb04a880302349c..1d1b0639ab96579b050e602753065c9d9f4ecba3 100644 (file)
@@ -45,20 +45,19 @@ static void save(const struct ipt_ip *ip, const struct ipt_entry_target *target)
 {
 }
 
-static
-struct iptables_target tarpit
-= { NULL,
-    "TARPIT",
-    IPTABLES_VERSION,
-    IPT_ALIGN(0),
-    IPT_ALIGN(0),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_target tarpit = {
+       .next           = NULL,
+       .name           = "TARPIT",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(0),
+       .userspacesize  = IPT_ALIGN(0),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 6892b5267d0c7f684af7ec7a84694570c2acdef2..c3256f00baa24886c1e87b73bd9073fd2595da1c 100644 (file)
@@ -113,20 +113,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_target *target)
                printf("--set-mss %u ", mssinfo->mss);
 }
 
-static
-struct iptables_target mss
-= { NULL,
-    "TCPMSS",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_tcpmss_info)),
-    IPT_ALIGN(sizeof(struct ipt_tcpmss_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_target mss = {
+       .next           = NULL,
+       .name           = "TCPMSS",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_tcpmss_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_tcpmss_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 87c38161d8a603f737efb498679cdba368457d48..4302950d615d56b58494dba2bd5e7a76d9ccd894 100644 (file)
@@ -153,20 +153,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_target *target)
        printf("--set-tos 0x%02x ", tosinfo->tos);
 }
 
-static
-struct iptables_target tos
-= { NULL,
-    "TOS",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_tos_target_info)),
-    IPT_ALIGN(sizeof(struct ipt_tos_target_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_target tos = {
+       .next           = NULL,
+       .name           = "TOS",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_tos_target_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_tos_target_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index cdf1f88ebd286c03ea0a188fd29c2f7b0684acf7..ca83f295b0a07da188be496226e55903784f1c2e 100644 (file)
@@ -1,7 +1,7 @@
 /* Shared library add-on to iptables for the TTL target
  * (C) 2000 by Harald Welte <laforge@gnumonks.org>
  *
- * $Id: libipt_TTL.c,v 1.6 2002/05/29 13:08:16 laforge Exp $
+ * $Id$
  *
  * This program is distributed under the terms of GNU GPL
  */
@@ -145,19 +145,19 @@ static struct option opts[] = {
        { 0 }
 };
 
-static
-struct iptables_target TTL = { NULL, 
-       "TTL",
-       IPTABLES_VERSION,
-       IPT_ALIGN(sizeof(struct ipt_TTL_info)),
-       IPT_ALIGN(sizeof(struct ipt_TTL_info)),
-       &help,
-       &init,
-       &parse,
-       &final_check,
-       &print,
-       &save,
-       opts 
+static struct iptables_target TTL = {
+       .next           = NULL, 
+       .name           = "TTL",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_TTL_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_TTL_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts 
 };
 
 void _init(void)
index 5ced4628b2bafd44581dbc848fa495277d435ef5..e0731416383f74207413ebd6d16289c48258f47a 100644 (file)
@@ -208,19 +208,19 @@ print(const struct ipt_ip *ip,
 #endif
 }
 
-static
-struct iptables_target ulog = { NULL,
-       "ULOG",
-       IPTABLES_VERSION,
-       IPT_ALIGN(sizeof(struct ipt_ulog_info)),
-       IPT_ALIGN(sizeof(struct ipt_ulog_info)),
-       &help,
-       &init,
-       &parse,
-       &final_check,
-       &print,
-       &save,
-       opts
+static struct iptables_target ulog = {
+       .next           = NULL,
+       .name           = "ULOG",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_ulog_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_ulog_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 47d8baacc1a3d159c52dc609dee1fbb7f9889e77..23979164cb21740120a12112345918a74e1bfba7 100644 (file)
@@ -93,18 +93,19 @@ static struct option opts[] = {
        { 0 }
 };
 
-static struct iptables_target XOR = { NULL, 
-       "XOR",
-       IPTABLES_VERSION,
-       IPT_ALIGN(sizeof(struct ipt_XOR_info)),
-       IPT_ALIGN(sizeof(struct ipt_XOR_info)),
-       &help,
-       &init,
-       &parse,
-       &final_check,
-       &print,
-       &save,
-       opts 
+static struct iptables_target XOR = {
+       .next           = NULL, 
+       .name           = "XOR",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_XOR_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_XOR_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts 
 };
 
 void _init(void)
index 093e9152d2cecc5282e06330eed1dc75ea42b5a8..9a82cc5cdc905457bc331f8c6db50487798935e4 100644 (file)
@@ -193,18 +193,18 @@ static struct option opts[] = {
 
 static
 struct iptables_match addrtype = {
-       NULL,
-       "addrtype",
-       IPTABLES_VERSION,
-       IPT_ALIGN(sizeof(struct ipt_addrtype_info)),
-       IPT_ALIGN(sizeof(struct ipt_addrtype_info)),
-       &help,
-       &init,
-       &parse,
-       &final_check,
-       &print,
-       &save,
-       opts
+       .next           = NULL,
+       .name           = "addrtype",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_addrtype_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_addrtype_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 
index 1e583989a9a472cc86874a9667fc8cec55bdbedd..443c9f8286b691e8340c4676a72683b8afcfded1 100644 (file)
@@ -168,20 +168,19 @@ static void save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
 
 }
 
-static
-struct iptables_match ah
-= { NULL,
-    "ah",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_ah)),
-    IPT_ALIGN(sizeof(struct ipt_ah)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match ah = { 
+       .next           = NULL,
+       .name           = "ah",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_ah)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_ah)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void
index 778051e89f4bd432a2f671e930071322640ed17a..253b267f8711aa844b95c5eb128b638041bcc506 100644 (file)
@@ -107,18 +107,18 @@ save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
 }
 
 static struct iptables_match comment = {
-    NULL,
-    "comment",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_comment_info)),
-    IPT_ALIGN(sizeof(struct ipt_comment_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+    .next              = NULL,
+    .name              = "comment",
+    .version           = IPTABLES_VERSION,
+    .size              = IPT_ALIGN(sizeof(struct ipt_comment_info)),
+    .userspacesize     = IPT_ALIGN(sizeof(struct ipt_comment_info)),
+    .help              = &help,
+    .init              = &init,
+    .parse             = &parse,
+    .final_check       = &final_check,
+    .print             = &print,
+    .save              = &save,
+    .extra_opts                = opts
 };
 
 void _init(void)
index 750111b49bb507d8aa28749c29db619bf46e77d4..553739d06d2611c097172b254149aa5920285c59 100644 (file)
@@ -94,17 +94,17 @@ save(const struct ipt_ip *ip,
 
 
 static struct iptables_match condition = {
-       .name = "condition",
-       .version = IPTABLES_VERSION,
-       .size = IPT_ALIGN(sizeof(struct condition_info)),
-       .userspacesize = IPT_ALIGN(sizeof(struct condition_info)),
-       .help = &help,
-       .init = &init,
-       .parse = &parse,
-       .final_check = &final_check,
-       .print = &print,
-       .save = &save,
-       .extra_opts = opts
+       .name           = "condition",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct condition_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct condition_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 
index 3bc314cc9734a1aafccc7c3660a2a99df4d5be8d..2d61a4af8694f41111bb075e0fc8b9073a807f32 100644 (file)
@@ -192,20 +192,19 @@ static void save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
        print_direction(sinfo);
 }
 
-static
-struct iptables_match state
-= { NULL,
-    "connbytes",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_connbytes_info)),
-    IPT_ALIGN(sizeof(struct ipt_connbytes_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match state = {
+       .next           = NULL,
+       .name           = "connbytes",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_connbytes_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_connbytes_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 4b61701b2201a2156b58bd07aaf658bb6ab99f99..54f021127ba2d0caccb98153fc41f7f2a0f4a29b 100644 (file)
@@ -122,17 +122,17 @@ static void save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
 }
 
 static struct iptables_match connlimit = {
-       name:           "connlimit",
-       version:        IPTABLES_VERSION,
-       size:           IPT_ALIGN(sizeof(struct ipt_connlimit_info)),
-       userspacesize:  offsetof(struct ipt_connlimit_info,data),
-       help:           help,
-       init:           init,
-       parse:          parse,
-       final_check:    final_check,
-       print:          print,
-       save:           save,
-       extra_opts:     opts
+       .name           = "connlimit",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_connlimit_info)),
+       .userspacesize  = offsetof(struct ipt_connlimit_info,data),
+       .help           = help,
+       .init           = init,
+       .parse          = parse,
+       .final_check    = final_check,
+       .print          = print,
+       .save           = save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index a952cb7e408167cd7c914387f769b7b8d9510bd6..3c76a70d7d6654dd214a601b06cec0f1574a4508 100644 (file)
@@ -167,20 +167,19 @@ static void save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
        printf(" ");
 }
 
-static
-struct iptables_match state
-= { NULL,
-    "connrate",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_connrate_info)),
-    IPT_ALIGN(sizeof(struct ipt_connrate_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match state = { 
+       .next           = NULL,
+       .name           = "connrate",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_connrate_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_connrate_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 63a07a7742907feaafddfad44f6bf95a228d8eb7..6ec77dc4e0a2f31c11339489e7dd6f6dbd4c1e91 100644 (file)
@@ -531,20 +531,19 @@ static void save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
        matchinfo_print(ip, match, 1, "--");
 }
 
-static
-struct iptables_match conntrack
-= { NULL,
-    "conntrack",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_conntrack_info)),
-    IPT_ALIGN(sizeof(struct ipt_conntrack_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match conntrack = { 
+       .next           = NULL,
+       .name           = "conntrack",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_conntrack_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_conntrack_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 1d61da89ea238f6470a65e3e76d6379ba439c6c8..b4e8b52691dd0b69950a4a1aca44aa3429893394 100644 (file)
@@ -157,20 +157,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
        print_dscp(dinfo->dscp, dinfo->invert, 1);
 }
 
-static
-struct iptables_match dscp
-= { NULL,
-    "dscp",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_dscp_info)),
-    IPT_ALIGN(sizeof(struct ipt_dscp_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match dscp = { 
+       .next           = NULL,
+       .name           = "dscp",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_dscp_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_dscp_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 32d73321dd2ad2558f74282af4ee0c69d48ed5c5..c4e90c6d2151a6a7c2f1f404fe3796aad426c320 100644 (file)
@@ -320,21 +320,20 @@ static void save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
                printf("--dstlimit-htable-expire %u ", r->cfg.expire);
 }
 
-static
-struct iptables_match dstlimit
-= { NULL,
-    "dstlimit",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_dstlimit_info)),
-    IPT_ALIGN(sizeof(struct ipt_dstlimit_info)),
-    //offsetof(struct ipt_dstlimit_info, prev),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match dstlimit = { 
+       .next           = NULL,
+       .name           = "dstlimit",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_dstlimit_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_dstlimit_info)),
+       //offsetof(struct ipt_dstlimit_info, prev),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .opts_extra     = opts
 };
 
 void _init(void)
index 531fdd112ad389274f1be8bff3d7491fcd7fc17d..4abfba307a0281b9f588edaae3441db0d874a095 100644 (file)
@@ -168,20 +168,19 @@ static void save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
 
 }
 
-static
-struct iptables_match esp
-= { NULL,
-    "esp",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_esp)),
-    IPT_ALIGN(sizeof(struct ipt_esp)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match esp = { 
+       .next           = NULL,
+       .name           = "esp",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_esp)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_esp)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void
index 6ebcb9f4cd29b50751c2eca97ceb6579b57b3a15..40e071d4fd838532e36f5693117d2ce2d8152e8a 100644 (file)
@@ -138,19 +138,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
 
 }
 
-struct iptables_match fuzzy_match
-= { NULL,
-    "fuzzy",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_fuzzy_info)),
-    IPT_ALIGN(sizeof(struct ipt_fuzzy_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match fuzzy_match = { 
+       .next           = NULL,
+       .name           = "fuzzy",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_fuzzy_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_fuzzy_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index caa444fb53ba7ea6d88f41963b02631ae4286054..f59b66724b46baa7c856bc2196bf442634b93523 100644 (file)
@@ -347,21 +347,19 @@ static void save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
                printf("--hashlimit-htable-expire %u ", r->cfg.expire);
 }
 
-static
-struct iptables_match hashlimit
-= { NULL,
-    "hashlimit",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_hashlimit_info)),
-    IPT_ALIGN(sizeof(struct ipt_hashlimit_info)),
-    //offsetof(struct ipt_hashlimit_info, prev),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match hashlimit = { NULL,
+       .name           = "hashlimit",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_hashlimit_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_hashlimit_info)),
+       //offsetof(struct ipt_hashlimit_info, prev),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 72660d94dcb9fe99b596571fb239fa2f0514a762..82c1ee0974cf4e1928f47ff1f96bc1d190dc9f12 100644 (file)
@@ -87,20 +87,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
        printf("%s--helper \"%s\" ",info->invert ? "! " : "", info->name);
 }
 
-static
-struct iptables_match helper
-= { NULL,
-    "helper",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_helper_info)),
-    IPT_ALIGN(sizeof(struct ipt_helper_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match helper = { 
+       .next           = NULL,
+       .name           = "helper",
+       .version        = IPTABLES_VERSION,
+       .release        = IPT_ALIGN(sizeof(struct ipt_helper_info)),
+       .size           = IPT_ALIGN(sizeof(struct ipt_helper_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index f61593e1609fc24aec359af1524e3575a7d967ec..32c04f6df771d8e4265797c73c5cea10b1920277 100644 (file)
@@ -287,20 +287,19 @@ static void final_check(unsigned int flags)
 {
 }
 
-static
-struct iptables_match icmp
-= { NULL,
-    "icmp",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_icmp)),
-    IPT_ALIGN(sizeof(struct ipt_icmp)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match icmp = { 
+       .next           = NULL,
+       .name           = "icmp",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_icmp)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_icmp)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 7e1a8cd698d66b112887a2e4f5ab74c7418dce3b..7d5c133418c13861e32e616fffbbeabde57d4327 100644 (file)
@@ -173,20 +173,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
        }
 }
 
-static
-struct iptables_match iprange
-= { NULL,
-    "iprange",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_iprange_info)),
-    IPT_ALIGN(sizeof(struct ipt_iprange_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match iprange = { 
+       .next           = NULL,
+       .name           = "iprange",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_iprange_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_iprange_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 2aec10be2a0a1f3767df8d5df76db3cbb44c2088..dd3e80a81546b3cb837619cebf975ff9aa47fbdf 100644 (file)
@@ -299,20 +299,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
        printf(" ");
 }
 
-static
-struct iptables_match ipv4options_struct
-= { NULL,
-    "ipv4options",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_ipv4options_info)),
-    IPT_ALIGN(sizeof(struct ipt_ipv4options_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match ipv4options_struct = { 
+       .next           = NULL,
+       .name           = "ipv4options",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_ipv4options_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_ipv4options_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 8ac98b624c578eae89ebc608fccb5d95fa00eaa6..fcd14bcbc16698c2d58c399290868e8784b4690a 100644 (file)
@@ -138,20 +138,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
        print_length((struct ipt_length_info *)match->data);
 }
 
-static
-struct iptables_match length
-= { NULL,
-    "length",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_length_info)),
-    IPT_ALIGN(sizeof(struct ipt_length_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match length = { 
+       .next           = NULL,
+       .name           = "length",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_length_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_length_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 2b155806468686ce61d1faf5111425b66d93e284..ad5e273307d92880349f5b98072e263f3dbd4d77 100644 (file)
@@ -177,20 +177,19 @@ static void save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
                printf("--limit-burst %u ", r->burst);
 }
 
-static
-struct iptables_match limit
-= { NULL,
-    "limit",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_rateinfo)),
-    offsetof(struct ipt_rateinfo, prev),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match limit = { 
+       .next           = NULL,
+       .name           = "limit",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_rateinfo)),
+       .userspacesize  = offsetof(struct ipt_rateinfo, prev),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index d1079a5ea246889950ef4ad6635aa1a7c0817493..30da7fabc976f52b825fcceb01c0e241a16054aa 100644 (file)
@@ -128,20 +128,19 @@ static void save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
        print_mac(((struct ipt_mac_info *)match->data)->srcaddr);
 }
 
-static
-struct iptables_match mac
-= { NULL,
-    "mac",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_mac_info)),
-    IPT_ALIGN(sizeof(struct ipt_mac_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match mac = { 
+       .next           = NULL,
+       .name           = "mac",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_mac_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_mac_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 14e179aec1c793d98a81690ca1e24ae2b5f22e06..1e031ca8994759507a2b1b30fab349f3b8646211 100644 (file)
@@ -131,20 +131,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
        print_mark(info->mark, info->mask, 0);
 }
 
-static
-struct iptables_match mark
-= { NULL,
-    "mark",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_mark_info)),
-    IPT_ALIGN(sizeof(struct ipt_mark_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match mark = { 
+       .next           = NULL,
+       .name           = "mark",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_mark_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_mark_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 28568db0e9cb3717c9162a3b6c9b4c9447f16127..63acbd9bd00fd48ad9584491b782b90d1b4187a3 100644 (file)
@@ -292,19 +292,19 @@ static void save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
        printf(" ");
 }
 
-struct iptables_match mport
-= { NULL,
-    "mport",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_mport)),
-    IPT_ALIGN(sizeof(struct ipt_mport)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match mport = { 
+       .next           = NULL,
+       .name           = "mport",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_mport)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_mport)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void
index efcb58eac43e996bdb7c4a062020d2145bbde14d..9420d5c02aaf401cfa830bff9214b7ccfb487360 100644 (file)
@@ -249,20 +249,19 @@ static void save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
        printf(" ");
 }
 
-static
-struct iptables_match multiport
-= { NULL,
-    "multiport",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_multiport)),
-    IPT_ALIGN(sizeof(struct ipt_multiport)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match multiport = { 
+       .next           = NULL,
+       .name           = "multiport",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_multiport)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_multiport)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void
index 764c9b9791c6ef24b04bbfad3116004fda7635ee..569b1ade24d77938a2af86785599b91584e3e0e4 100644 (file)
@@ -217,19 +217,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
                 printf("--packet %u ", nthinfo->packet );
 }
 
-struct iptables_match nth
-= { NULL,
-    "nth",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_nth_info)),
-    IPT_ALIGN(sizeof(struct ipt_nth_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match nth = { 
+       .next           = NULL,
+       .name           = "nth",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_nth_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_nth_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 671efbb5a2447f86d6ce91a1fedb970e45e907f3..46da9e337460d080be5cf1094a41fcf8c994d98a 100644 (file)
@@ -238,20 +238,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
 #endif
 }
 
-static
-struct iptables_match owner
-= { NULL,
-    "owner",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_owner_info)),
-    IPT_ALIGN(sizeof(struct ipt_owner_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match owner = { 
+       .next           = NULL,
+       .name           = "owner",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_owner_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_owner_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 9149d9031588462e3e1ebfcc6733371d1742a540..0c4c35761fe5cf8f2a445ff05f4aebba7fa8c4a1 100644 (file)
@@ -210,20 +210,19 @@ static void save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
        printf(" ");
 }
 
-static
-struct iptables_match physdev
-= { NULL,
-    "physdev",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_physdev_info)),
-    IPT_ALIGN(sizeof(struct ipt_physdev_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match physdev = { 
+       .next           = NULL,
+       .name           = "physdev",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_physdev_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_physdev_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 9141e480d48b5ffd0872325e5d81209dd2553104..af220955187d35d1fcae811007dc0a19bc38a581 100644 (file)
@@ -152,20 +152,19 @@ static void save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
        print_pkttype(info);
 }
 
-static
-struct iptables_match pkttype = {
-    NULL,
-    "pkttype",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_pkttype_info)),
-    IPT_ALIGN(sizeof(struct ipt_pkttype_info)),
-    &help,
-    &init,
-    &parse, 
-    &final_check, 
-    &print,
-    &save, 
-    opts
+static struct iptables_match pkttype = {
+       .next           = NULL,
+       .name           = "pkttype",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_pkttype_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_pkttype_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse, 
+       .final_check    = &final_check, 
+       .print          = &print,
+       .save           = &save, 
+       .extra_opts     = opts
 };
 
 void _init(void)
index 082d76c25887ab01fbf6a8aca5130ce67354198d..7e204dad9619f925083b2ea3664510b4ae1d14c6 100644 (file)
@@ -122,20 +122,19 @@ static void save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
                        ip_pool_get_name(buf, sizeof(buf), info->dst, 0));
 }
 
-static
-struct iptables_match pool
-= { NULL,
-    "pool",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_pool_info)),
-    IPT_ALIGN(sizeof(struct ipt_pool_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match pool = { 
+       .next           = NULL,
+       .name           = "pool",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_pool_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_pool_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 068430d9e56b10ec2b46aedea90c54e31d842379..e150e09e554e4404177da6644765e3e9c978a60d 100644 (file)
@@ -175,20 +175,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
        printf("--psd-hi-ports-weight %u ", psdinfo->hi_ports_weight);
 }
 
-static
-struct iptables_match psd
-= { NULL,
-    "psd",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_psd_info)),
-    IPT_ALIGN(sizeof(struct ipt_psd_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match psd = { 
+       .next           = NULL,
+       .name           = "psd",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_psd_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_psd_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 078f9e352ba1673a4a5f30cf9052574369ffe4ac..b0de7adb7387dd61053ea37eeb07f9f32ca57e4d 100644 (file)
@@ -93,18 +93,19 @@ final_check(unsigned int flags)
 {
 }
 
-struct iptables_match quota = { NULL,
-        "quota",
-        IPTABLES_VERSION,
-        IPT_ALIGN(sizeof (struct ipt_quota_info)),
-        IPT_ALIGN(sizeof (struct ipt_quota_info)),
-        &help,
-        &init,
-        &parse,
-        &final_check,
-        &print,
-        &save,
-        opts
+struct iptables_match quota = { 
+       .next           = NULL,
+       .name           = "quota",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof (struct ipt_quota_info)),
+       .userspacesize  = IPT_ALIGN(sizeof (struct ipt_quota_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void
index 273501ae11fc6a4ded50276952eebbd8e65bbda0..fd815bbcd5a314da460c8296fb30d65b8b618d3f 100644 (file)
@@ -130,19 +130,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
        printf("--average %u ", result.quot);
 }
 
-struct iptables_match rand_match
-= { NULL,
-    "random",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_rand_info)),
-    IPT_ALIGN(sizeof(struct ipt_rand_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+struct iptables_match rand_match = { 
+       .next           = NULL,
+       .name           = "random",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_rand_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_rand_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 13bc17caaa7289278ad321aad7a42312df1f6538..c8b4f8f7eb500a4e12806a4356c28b48f4fb8023 100644 (file)
@@ -113,19 +113,18 @@ final_check(unsigned int flags)
                           "REALM match: You must specify `--realm'");
 }
 
-struct iptables_match realm
-= { NULL,
-    "realm",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_realm_info)),
-    IPT_ALIGN(sizeof(struct ipt_realm_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match realm = { NULL,
+       .name           = "realm",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_realm_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_realm_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 7fb058665661e513292ab8917480f7b89a138703..0717795984043fb5c81b826f2753c2d32e116cb5 100644 (file)
@@ -352,18 +352,19 @@ static void save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
 }
 
 
-static struct iptables_match rpcstruct = { NULL,
-    "rpc",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_rpc_info)),
-    IPT_ALIGN(sizeof(struct ipt_rpc_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match rpcstruct = { 
+       .next           = NULL,
+       .name           = "rpc",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_rpc_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_rpc_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 
index d79ad7cfe5aac3cb735e20156b5b3a3a096396f3..4c5a3f5a5dfa49b1224824985c78db6ab58453c9 100644 (file)
@@ -48,19 +48,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_target *target)
 }
 
 static
-struct iptables_target standard
-= { NULL,
-    "standard",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(int)),
-    IPT_ALIGN(sizeof(int)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    NULL, /* print */
-    &save,
-    opts
+struct iptables_target standard = { 
+       .next           = NULL,
+       .name           = "standard",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(int)),
+       .userspacesize  = IPT_ALIGN(sizeof(int)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = NULL,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 3662d949abff829ee8418e59967ed0542f0a3e76..8e6a90c566af5b29ec83da2e78efbe30fcd661f1 100644 (file)
@@ -151,20 +151,19 @@ static void save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
        print_state(sinfo->statemask);
 }
 
-static
-struct iptables_match state
-= { NULL,
-    "state",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_state_info)),
-    IPT_ALIGN(sizeof(struct ipt_state_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match state = { 
+       .next           = NULL,
+       .name           = "state",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_state_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_state_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 37613ac0c174473bfb4c5537eb169bb4c469d145..57515006a13e8e41f6e9605a8a52d661f87962a7 100644 (file)
@@ -423,20 +423,20 @@ static void save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
        }
 }
 
-static
-struct iptables_match tcp
-= { NULL,
-    "tcp",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_tcp)),
-    IPT_ALIGN(sizeof(struct ipt_tcp)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts };
+static struct iptables_match tcp = { 
+       .next           = NULL,
+       .name           = "tcp",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_tcp)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_tcp)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
+};
 
 void
 _init(void)
index 2eb9797e85842e581860fc610f86454f48c1284e..d596ea74e750cb63667f5a83695bbffe540125d9 100644 (file)
@@ -139,20 +139,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
                     mssinfo->invert, 0);
 }
 
-static
-struct iptables_match tcpmss
-= { NULL,
-    "tcpmss",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_tcpmss_match_info)),
-    IPT_ALIGN(sizeof(struct ipt_tcpmss_match_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match tcpmss = {
+       .next           = NULL,
+       .name           = "tcpmss",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_tcpmss_match_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_tcpmss_match_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index d700f86d5c7c6b6b24f2fe31c548aa30b2766e3f..cceab58d11b3396ef5846292cf83d3e6bd989d92 100644 (file)
@@ -530,19 +530,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
 /* have to use offsetof() instead of IPT_ALIGN(), since kerneltime must not
  * be compared when user deletes rule with '-D' */
 static
-struct iptables_match timestruct
-= { NULL,
-    "time",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_time_info)),
-    offsetof(struct ipt_time_info, kerneltime),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+struct iptables_match timestruct = {
+       .next           = NULL,
+       .name           = "time",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_time_info)),
+       .userspacesize  = offsetof(struct ipt_time_info, kerneltime),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index 0d6a1d04c3afcbae0104473f0ad9c00b507b9a35..6241950ad7935470157720413a2ad7a9bc9d115d 100644 (file)
@@ -159,20 +159,19 @@ save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
        print_tos(info->tos, 0);
 }
 
-static
-struct iptables_match tos
-= { NULL,
-    "tos",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_tos_info)),
-    IPT_ALIGN(sizeof(struct ipt_tos_info)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+static struct iptables_match tos = { 
+       .next           = NULL,
+       .name           = "tos",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_tos_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_tos_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void _init(void)
index ce87368bc08f9e60afb0ee691996ee67e4a17244..8d47dbecf04e0efb6fab8faa25c709dca7e88ed2 100644 (file)
@@ -149,20 +149,19 @@ static struct option opts[] = {
        { 0 }
 };
 
-static
-struct iptables_match ttl = {
-       NULL,
-       "ttl",
-       IPTABLES_VERSION,
-       IPT_ALIGN(sizeof(struct ipt_ttl_info)),
-       IPT_ALIGN(sizeof(struct ipt_ttl_info)),
-       &help,
-       &init,
-       &parse,
-       &final_check,
-       &print,
-       &save,
-       opts
+static struct iptables_match ttl = {
+       .next           = NULL,
+       .name           = "ttl",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_ttl_info)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_ttl_info)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 
index 1eea83f641835963ed66c5a6c9b549e5d3bd4df1..c5f5b4d92abaa07f0cb93cd835a644867f7c1431 100644 (file)
@@ -250,19 +250,19 @@ static void save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
        print_u32((struct ipt_u32 *)match->data);
 }
 
-struct iptables_match u32
-= { NULL,
-    "u32",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_u32)),
-    IPT_ALIGN(sizeof(struct ipt_u32)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+struct iptables_match u32 = {
+       .next           = NULL,
+       .name           = "u32",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_u32)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_u32)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void
index ccea21054c3bbde50a72a3b591dae4ddb2a84c79..fb52cf018e1c41604a87fa6d867d66af753cdc14 100644 (file)
@@ -234,19 +234,19 @@ static void save(const struct ipt_ip *ip, const struct ipt_entry_match *match)
 }
 
 static
-struct iptables_match udp
-= { NULL,
-    "udp",
-    IPTABLES_VERSION,
-    IPT_ALIGN(sizeof(struct ipt_udp)),
-    IPT_ALIGN(sizeof(struct ipt_udp)),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    &print,
-    &save,
-    opts
+struct iptables_match udp = { 
+       .next           = NULL,
+       .name           = "udp",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(sizeof(struct ipt_udp)),
+       .userspacesize  = IPT_ALIGN(sizeof(struct ipt_udp)),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = &print,
+       .save           = &save,
+       .extra_opts     = opts
 };
 
 void
index 16cc0a51bac0cf854ee61216b25cc0f405c97760..a97b0f0eaf53e4a0a6d19619d4338fbbb44ef0e4 100644 (file)
@@ -42,19 +42,19 @@ static void final_check(unsigned int flags)
 }
 
 static
-struct iptables_match unclean
-= { NULL,
-    "unclean",
-    IPTABLES_VERSION,
-    IPT_ALIGN(0),
-    IPT_ALIGN(0),
-    &help,
-    &init,
-    &parse,
-    &final_check,
-    NULL, /* print */
-    NULL, /* save */
-    opts
+struct iptables_match unclean = { 
+       .next           = NULL,
+       .name           = "unclean",
+       .version        = IPTABLES_VERSION,
+       .size           = IPT_ALIGN(0),
+       .userspacesize  = IPT_ALIGN(0),
+       .help           = &help,
+       .init           = &init,
+       .parse          = &parse,
+       .final_check    = &final_check,
+       .print          = NULL,
+       .save           = NULL,
+       .extra_opts     = opts
 };
 
 void _init(void)