X-Git-Url: https://git.archive.openwrt.org/?a=blobdiff_plain;f=rules.h;h=bdd36a2fa2965a0c6dd1ea76260ae43fa7eddbaf;hb=e678dcbf0336c3ca10f9fe2fae8b19347b6c1d4d;hp=6d332fc61e5ca3002a49a70bc79a9f0335936994;hpb=2f392a3b91c25c94abfc9a7862d908c923f7bf2b;p=project%2Ffirewall3.git diff --git a/rules.h b/rules.h index 6d332fc..bdd36a2 100644 --- a/rules.h +++ b/rules.h @@ -27,10 +27,13 @@ extern const struct fw3_option fw3_rule_opts[]; -void fw3_load_rules(struct fw3_state *state, struct uci_package *p); +void fw3_load_rules(struct fw3_state *state, struct uci_package *p, struct blob_attr *a); void fw3_print_rules(struct fw3_ipt_handle *handle, struct fw3_state *state); -#define fw3_free_rule(rule) \ - fw3_free_object(rule, fw3_rule_opts) +static inline void fw3_free_rule(struct fw3_rule *rule) +{ + list_del(&rule->list); + fw3_free_object(rule, fw3_rule_opts); +} #endif