diff options
author | Pablo Neira Ayuso <pablo@netfilter.org> | 2020-03-31 13:36:16 +0200 |
---|---|---|
committer | Pablo Neira Ayuso <pablo@netfilter.org> | 2020-03-31 13:50:59 +0200 |
commit | 673d82af234e24ef841e8409426d5f082f9ea59e (patch) | |
tree | 97c79a625b4302ea89d046eea63c1f42a5ad2366 /include | |
parent | d6ac64f92dfca5da4d07989114a4aa46e1322453 (diff) |
rule: add hook_spec
Store location of chain hook definition.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'include')
-rw-r--r-- | include/rule.h | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/include/rule.h b/include/rule.h index db11b1d6..06fefef8 100644 --- a/include/rule.h +++ b/include/rule.h @@ -189,6 +189,12 @@ struct prio_spec { struct expr *expr; }; +struct hook_spec { + struct location loc; + const char *name; + unsigned int num; +}; + /** * struct chain - nftables chain * @@ -211,9 +217,8 @@ struct chain { struct location location; unsigned int refcnt; uint32_t flags; - const char *hookstr; - unsigned int hooknum; struct prio_spec priority; + struct hook_spec hook; struct expr *policy; const char *type; const char **dev_array; @@ -485,8 +490,7 @@ struct flowtable { struct handle handle; struct scope scope; struct location location; - const char * hookstr; - unsigned int hooknum; + struct hook_spec hook; struct prio_spec priority; const char **dev_array; struct expr *dev_expr; |