diff options
author | Jan Engelhardt <jengelh@medozas.de> | 2008-04-15 11:48:25 +0200 |
---|---|---|
committer | Patrick McHardy <kaber@trash.net> | 2008-04-15 14:01:06 +0200 |
commit | 8b7c64d6ba156a99008fcd810cba874c73294333 (patch) | |
tree | 47489e2ac7ae083087ec7f0675f1c2e5fc2b4d7a /extensions/libipt_DNAT.c | |
parent | ddcb288316c942a5b8de33edd5f03318db8906b7 (diff) |
Remove old functions, constants
Diffstat (limited to 'extensions/libipt_DNAT.c')
-rw-r--r-- | extensions/libipt_DNAT.c | 19 |
1 files changed, 9 insertions, 10 deletions
diff --git a/extensions/libipt_DNAT.c b/extensions/libipt_DNAT.c index 3ad412b6..fed7611c 100644 --- a/extensions/libipt_DNAT.c +++ b/extensions/libipt_DNAT.c @@ -23,12 +23,10 @@ struct ipt_natinfo static void DNAT_help(void) { printf( -"DNAT v%s options:\n" +"DNAT target options:\n" " --to-destination <ipaddr>[-<ipaddr>][:port-port]\n" " Address to map destination to.\n" -"[--random]\n" -"\n", -IPTABLES_VERSION); +"[--random]\n"); } static const struct option DNAT_opts[] = { @@ -43,7 +41,7 @@ append_range(struct ipt_natinfo *info, const struct ip_nat_range *range) unsigned int size; /* One rangesize already in struct ipt_natinfo */ - size = IPT_ALIGN(sizeof(*info) + info->mr.rangesize * sizeof(*range)); + size = XT_ALIGN(sizeof(*info) + info->mr.rangesize * sizeof(*range)); info = realloc(info, size); if (!info) @@ -243,11 +241,12 @@ static void DNAT_save(const void *ip, const struct xt_entry_target *target) } } -static struct iptables_target dnat_target = { +static struct xtables_target dnat_tg_reg = { .name = "DNAT", - .version = IPTABLES_VERSION, - .size = IPT_ALIGN(sizeof(struct ip_nat_multi_range)), - .userspacesize = IPT_ALIGN(sizeof(struct ip_nat_multi_range)), + .version = XTABLES_VERSION, + .family = PF_INET, + .size = XT_ALIGN(sizeof(struct ip_nat_multi_range)), + .userspacesize = XT_ALIGN(sizeof(struct ip_nat_multi_range)), .help = DNAT_help, .parse = DNAT_parse, .final_check = DNAT_check, @@ -258,5 +257,5 @@ static struct iptables_target dnat_target = { void _init(void) { - register_target(&dnat_target); + xtables_register_target(&dnat_tg_reg); } |