From a8ff324dc64fd76f7d218d3d94c5885250951258 Mon Sep 17 00:00:00 2001 From: Florian Westphal Date: Fri, 28 Jul 2023 21:04:13 +0200 Subject: ct expectation: fix 'list object x' vs. 'list objects in table' confusion Just like "ct timeout", "ct expectation" is in need of the same fix, we get segfault on "nft list ct expectation table t", if table t exists. This is the exact same pattern as resolved for "ct timeout" in commit 1d2e22fc0521 ("ct timeout: fix 'list object x' vs. 'list objects in table' confusion"). Signed-off-by: Florian Westphal --- src/cache.c | 1 + 1 file changed, 1 insertion(+) (limited to 'src/cache.c') diff --git a/src/cache.c b/src/cache.c index 5cab2622..b6a7e194 100644 --- a/src/cache.c +++ b/src/cache.c @@ -377,6 +377,7 @@ static int nft_handle_validate(const struct cmd *cmd, struct list_head *msgs) case CMD_OBJ_CT_TIMEOUT: case CMD_OBJ_CT_TIMEOUTS: case CMD_OBJ_CT_EXPECT: + case CMD_OBJ_CT_EXPECTATIONS: if (h->table.name && strlen(h->table.name) > NFT_NAME_MAXLEN) { loc = &h->table.location; -- cgit v1.2.3