diff options
author | Pablo Neira Ayuso <pablo@netfilter.org> | 2019-06-14 14:16:59 +0200 |
---|---|---|
committer | Pablo Neira Ayuso <pablo@netfilter.org> | 2019-06-14 14:35:16 +0200 |
commit | dc5372b6e8448549a770f9d09477fd2a9207d69c (patch) | |
tree | f10fff1748da9c53f42c0fed5c707740770d99c0 /src/cache.c | |
parent | ef5c498bd166b5284fdf80d95b03daaa7e05556a (diff) |
cache: do not populate the cache in case of flush ruleset command
__CMD_FLUSH_RULESET is a dummy definition that used to skip the netlink
dump to populate the cache. This patch is a workaround until we have a
better infrastructure to track the state of the cache objects.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'src/cache.c')
-rw-r--r-- | src/cache.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/cache.c b/src/cache.c index 532ef425..d7153f6f 100644 --- a/src/cache.c +++ b/src/cache.c @@ -54,6 +54,9 @@ static unsigned int evaluate_cache_flush(struct cmd *cmd) unsigned int completeness = CMD_INVALID; switch (cmd->obj) { + case CMD_OBJ_RULESET: + completeness = __CMD_FLUSH_RULESET; + break; case CMD_OBJ_SET: case CMD_OBJ_MAP: case CMD_OBJ_METER: |