--- ../patch-o-matic-ng/patchlets/IPMARK/iptables/extensions/libipt_IPMARK.c.orig 2006-12-04 12:15:20.000000000 +0100 +++ ../patch-o-matic-ng/patchlets/IPMARK/iptables/extensions/libipt_IPMARK.c 2008-03-13 21:51:12.000000000 +0100 @@ -19,7 +19,7 @@ #define IPT_OR_MASK_USED 4 struct ipmarkinfo { - struct ipt_entry_target t; + struct xt_entry_target t; struct ipt_ipmark_target_info ipmark; }; @@ -37,15 +37,15 @@ } static struct option opts[] = { - { "addr", 1, 0, '1' }, - { "and-mask", 1, 0, '2' }, - { "or-mask", 1, 0, '3' }, - { 0 } + { .name = "addr", .has_arg = 1, .flag = 0, .val = '1' }, + { .name = "and-mask", .has_arg = 1, .flag = 0, .val = '2' }, + { .name = "or-mask", .has_arg = 1, .flag = 0, .val = '3' }, + { .name = NULL } }; /* Initialize the target. */ static void -init(struct ipt_entry_target *t, unsigned int *nfcache) +init(struct xt_entry_target *t) { struct ipt_ipmark_target_info *ipmarkinfo = (struct ipt_ipmark_target_info *)t->data; @@ -59,8 +59,8 @@ ate an option */ static int parse(int c, char **argv, int invert, unsigned int *flags, - const struct ipt_entry *entry, - struct ipt_entry_target **target) + const void *entry, + struct xt_entry_target **target) { struct ipt_ipmark_target_info *ipmarkinfo = (struct ipt_ipmark_target_info *)(*target)->data; @@ -116,8 +116,8 @@ /* Prints out the targinfo. */ static void -print(const struct ipt_ip *ip, - const struct ipt_entry_target *target, +print(const void *ip, + const struct xt_entry_target *target, int numeric) { const struct ipt_ipmark_target_info *ipmarkinfo = @@ -132,7 +132,7 @@ /* Saves the union ipt_targinfo in parsable form to stdout. */ static void -save(const struct ipt_ip *ip, const struct ipt_entry_target *target) +save(const void *ip, const struct xt_entry_target *target) { const struct ipt_ipmark_target_info *ipmarkinfo = (const struct ipt_ipmark_target_info *)target->data; @@ -147,7 +147,7 @@ printf("--or-mask 0x%lx ", ipmarkinfo->ormask); } -static struct iptables_target ipmark = { +static struct xtables_target ipmark = { .next = NULL, .name = "IPMARK", .version = IPTABLES_VERSION,