From b85769f9397c72ab62387ccc5b7a66d0c3ff5f21 Mon Sep 17 00:00:00 2001 From: Pablo Neira Ayuso Date: Wed, 15 Sep 2021 01:05:52 +0200 Subject: src: revert hashtable for expression handlers Partially revert 913979f882d1 ("src: add expression handler hashtable") which is causing a crash with two instances of the nftables handler. $ sudo python [sudo] password for echerkashin: Python 3.9.7 (default, Sep 3 2021, 06:18:44) [GCC 11.2.0] on linux Type "help", "copyright", "credits" or "license" for more information. >>> from nftables import Nftables >>> n1=Nftables() >>> n2=Nftables() >>> double free or corruption (top) Aborted Reported-by: Eugene Crosser Suggested-by: Florian Westphal Signed-off-by: Pablo Neira Ayuso --- src/libnftables.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'src/libnftables.c') diff --git a/src/libnftables.c b/src/libnftables.c index aa6493aa..fc52fbc3 100644 --- a/src/libnftables.c +++ b/src/libnftables.c @@ -106,13 +106,11 @@ static void nft_init(struct nft_ctx *ctx) realm_table_rt_init(ctx); devgroup_table_init(ctx); ct_label_table_init(ctx); - expr_handler_init(); } static void nft_exit(struct nft_ctx *ctx) { cache_free(&ctx->cache.table_cache); - expr_handler_exit(); ct_label_table_exit(ctx); realm_table_rt_exit(ctx); devgroup_table_exit(ctx); -- cgit v1.2.3