summaryrefslogtreecommitdiffstats
path: root/include/rule.h
diff options
context:
space:
mode:
authorPhil Sutter <phil@nwl.cc>2023-12-15 01:10:39 +0100
committerPhil Sutter <phil@nwl.cc>2024-04-19 19:21:21 +0200
commit4955ae1a81b73f9a61b7fbf1a73e11544513548e (patch)
tree7883c0cd9e049bdb80d7694a174d31ee3b44a278 /include/rule.h
parent83ed57d587afb248dc5dc72006b247319193008d (diff)
Add support for table's persist flag
Bison parser lacked support for passing multiple flags, JSON parser did not support table flags at all. Document also 'owner' flag (and describe their relationship in nft.8. Signed-off-by: Phil Sutter <phil@nwl.cc>
Diffstat (limited to 'include/rule.h')
-rw-r--r--include/rule.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/include/rule.h b/include/rule.h
index 3a833cf3..5b3e12b5 100644
--- a/include/rule.h
+++ b/include/rule.h
@@ -130,10 +130,12 @@ struct symbol *symbol_get(const struct scope *scope, const char *identifier);
enum table_flags {
TABLE_F_DORMANT = (1 << 0),
TABLE_F_OWNER = (1 << 1),
+ TABLE_F_PERSIST = (1 << 2),
};
-#define TABLE_FLAGS_MAX 2
+#define TABLE_FLAGS_MAX 3
const char *table_flag_name(uint32_t flag);
+unsigned int parse_table_flag(const char *name);
/**
* struct table - nftables table