diff options
author | Jo-Philipp Wich <jow@openwrt.org> | 2009-12-17 01:07:44 +0000 |
---|---|---|
committer | Jo-Philipp Wich <jow@openwrt.org> | 2009-12-17 01:07:44 +0000 |
commit | 9903178ee7f107dc04a4ecf48eccde12353622f4 (patch) | |
tree | 482e2373e8f21cf03457f42f53c66517a9fd472d /contrib/fwd/src/fwd_rules.h | |
parent | 5abef1380ef5c4271aa1d26339306dccf04c9ab2 (diff) |
contrib/fwd: implement fwd_ipt_delif() and fwd_ipt_clear_ruleset()
Diffstat (limited to 'contrib/fwd/src/fwd_rules.h')
-rw-r--r-- | contrib/fwd/src/fwd_rules.h | 19 |
1 files changed, 3 insertions, 16 deletions
diff --git a/contrib/fwd/src/fwd_rules.h b/contrib/fwd/src/fwd_rules.h index 7074622e34..f3492c5801 100644 --- a/contrib/fwd/src/fwd_rules.h +++ b/contrib/fwd/src/fwd_rules.h @@ -21,24 +21,11 @@ #include "fwd.h" -#define IPT "iptables" - -struct fwd_ipt_rulebuf { - char *buf; - size_t len; -}; - - -#define fwd_ipt_add_format fwd_ipt_rule_append - -#define fwd_ipt_exec_format(t, ...) do { \ - struct fwd_ipt_rulebuf *r = fwd_ipt_init(t); \ - fwd_ipt_add_format(r, __VA_ARGS__); \ - fwd_ipt_exec(r); \ -} while(0) - void fwd_ipt_build_ruleset(struct fwd_handle *h); +void fwd_ipt_clear_ruleset(struct fwd_handle *h); + void fwd_ipt_addif(struct fwd_handle *h, const char *net); +void fwd_ipt_delif(struct fwd_handle *h, const char *net); #endif |