Do not report success if chain cache list cannot be built. Signed-off-by: Pablo Neira Ayuso <pablo@xxxxxxxxxxxxx> --- src/cache.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/cache.c b/src/cache.c index 80632c86caa6..f032171a95ff 100644 --- a/src/cache.c +++ b/src/cache.c @@ -365,7 +365,7 @@ static int cache_init_objects(struct netlink_ctx *ctx, unsigned int flags) if (flags & NFT_CACHE_CHAIN_BIT) { chain_list = chain_cache_dump(ctx, &ret); if (!chain_list) - return ret; + return -1; } list_for_each_entry(table, &ctx->nft->cache.list, list) { -- 2.20.1