X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=extensions%2Flibip6t_length.c;fp=extensions%2Flibip6t_length.c;h=c944c65e093674de97a1362100394cc26814b928;hb=6afea0b41dfbc3824956d11d960ad80097218feb;hp=b8fa15b4db5ac6016a695b0d8a94688b0095c570;hpb=f7b70cf9e00324b89b02de213bcd0dde7044d035;p=iptables.git diff --git a/extensions/libip6t_length.c b/extensions/libip6t_length.c index b8fa15b..c944c65 100644 --- a/extensions/libip6t_length.c +++ b/extensions/libip6t_length.c @@ -26,13 +26,6 @@ static struct option opts[] = { {0} }; -/* Initialize the match. */ -static void -init(struct ip6t_entry_match *m, unsigned int *nfcache) -{ - *nfcache |= NFC_UNKNOWN; -} - static u_int16_t parse_length(const char *s) { @@ -140,19 +133,17 @@ save(const struct ip6t_ip6 *ip, const struct ip6t_entry_match *match) print_length((struct ip6t_length_info *)match->data); } -struct ip6tables_match length -= { NULL, - "length", - IPTABLES_VERSION, - IP6T_ALIGN(sizeof(struct ip6t_length_info)), - IP6T_ALIGN(sizeof(struct ip6t_length_info)), - &help, - &init, - &parse, - &final_check, - &print, - &save, - opts +struct ip6tables_match length = { + .name = "length", + .version = IPTABLES_VERSION, + .size = IP6T_ALIGN(sizeof(struct ip6t_length_info)), + .userspacesize = IP6T_ALIGN(sizeof(struct ip6t_length_info)), + .help = &help, + .parse = &parse, + .final_check = &final_check, + .print = &print, + .save = &save, + .extra_opts = opts, }; void _init(void)