[iptables PATCH 02/28] xtables: Fix for wrong assert() in __nft_table_flush()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The code obviously tries to assert that nft_table_builtin_find()
returned a valid pointer before dereferencing it, but the wrong argument
was given. Assume this is just a typo and insert the missing underscore.

Fixes: 9b896224e0bfc ("xtables: rework rule cache logic")
Signed-off-by: Phil Sutter <phil@xxxxxx>
---
 iptables/nft.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/iptables/nft.c b/iptables/nft.c
index 48198edf4573c..c67718c882a64 100644
--- a/iptables/nft.c
+++ b/iptables/nft.c
@@ -1899,7 +1899,7 @@ static int __nft_table_flush(struct nft_handle *h, const char *table)
 	batch_table_add(h, NFT_COMPAT_TABLE_FLUSH, t);
 
 	_t = nft_table_builtin_find(h, table);
-	assert(t);
+	assert(_t);
 	_t->initialized = false;
 
 	flush_chain_cache(h, table);
-- 
2.18.0




[Index of Archives]     [Netfitler Users]     [LARTC]     [Bugtraq]     [Yosemite Forum]

  Powered by Linux