From 79dee0702b18c8ea1d1f7a2b1f6b29349466986b Mon Sep 17 00:00:00 2001 From: Rusty Russell Date: Tue, 2 May 2000 16:45:16 +0000 Subject: IPv6 enhancements. --- include/iptables.h | 28 +++++++++++----------------- 1 file changed, 11 insertions(+), 17 deletions(-) (limited to 'include/iptables.h') diff --git a/include/iptables.h b/include/iptables.h index 1ddd8712..886d576b 100644 --- a/include/iptables.h +++ b/include/iptables.h @@ -1,6 +1,7 @@ #ifndef _IPTABLES_USER_H #define _IPTABLES_USER_H +#include "iptables_common.h" #include "libiptc/libiptc.h" /* Include file for additions: new matches and targets. */ @@ -38,7 +39,7 @@ struct iptables_match void (*print)(const struct ipt_ip *ip, const struct ipt_entry_match *match, int numeric); - /* Saves the union ipt_matchinfo in parsable form to stdout. */ + /* Saves the match info in parsable form to stdout. */ void (*save)(const struct ipt_ip *ip, const struct ipt_entry_match *match); @@ -101,21 +102,8 @@ struct iptables_target extern void register_match(struct iptables_match *me); extern void register_target(struct iptables_target *me); -/* Functions we share */ -enum exittype { - OTHER_PROBLEM = 1, - PARAMETER_PROBLEM, - VERSION_PROBLEM -}; -extern void exit_printhelp() __attribute__((noreturn)); -extern void exit_tryhelp(int) __attribute__((noreturn)); -int check_inverse(const char option[], int *invert); -extern int string_to_number(const char *, int, int); -void exit_error(enum exittype, char *, ...)__attribute__((noreturn, - format(printf,2,3))); +extern struct in_addr *dotted_to_addr(const char *dotted); extern char *addr_to_dotted(const struct in_addr *addrp); -struct in_addr *dotted_to_addr(const char *dotted); -extern const char *program_name, *program_version; extern int do_command(int argc, char *argv[], char **table, iptc_handle_t *handle); @@ -123,6 +111,12 @@ extern int do_command(int argc, char *argv[], char **table, extern struct iptables_match *iptables_matches; extern struct iptables_target *iptables_targets; -extern struct iptables_target *find_target(const char *name, int tryload); -extern struct iptables_match *find_match(const char *name, int tryload); +enum ipt_tryload { + DONT_LOAD, + TRY_LOAD, + LOAD_MUST_SUCCEED +}; + +extern struct iptables_target *find_target(const char *name, enum ipt_tryload); +extern struct iptables_match *find_match(const char *name, enum ipt_tryload); #endif /*_IPTABLES_USER_H*/ -- cgit v1.2.3