diff options
author | Pablo Neira Ayuso <pablo@netfilter.org> | 2013-07-13 21:21:27 +0200 |
---|---|---|
committer | Pablo Neira Ayuso <pablo@netfilter.org> | 2013-07-13 21:35:23 +0200 |
commit | 4dd0772911a2c92a43d4e4aecf305fba498be106 (patch) | |
tree | 0b40bca77b673de3102c8466d6b25ce07711fb99 /src/expr_ops.h | |
parent | 013227cb6f13cbab2fbccbeb750199a051fd7a43 (diff) |
expr: use __attribute__((constructor)) to register expression
Instead of manual array registration.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'src/expr_ops.h')
-rw-r--r-- | src/expr_ops.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/expr_ops.h b/src/expr_ops.h index 18edfd1..d8a0b36 100644 --- a/src/expr_ops.h +++ b/src/expr_ops.h @@ -14,6 +14,8 @@ struct nft_rule_expr; #endif struct expr_ops { + struct list_head head; + char *name; size_t alloc_len; int max_attr; @@ -25,6 +27,7 @@ struct expr_ops { int (*xml_parse)(struct nft_rule_expr *e, mxml_node_t *tree); }; +void nft_expr_ops_register(struct expr_ops *ops); struct expr_ops *nft_expr_ops_lookup(const char *name); #endif |