提交 2b4e5fb4 编写于 作者: P Pablo Neira Ayuso

netfilter: nft_synproxy: unregister hooks on init error path

Disable the IPv4 hooks if the IPv6 hooks fail to be registered.

Fixes: ad49d86e ("netfilter: nf_tables: Add synproxy support")
Signed-off-by: NPablo Neira Ayuso <pablo@netfilter.org>
上级 2e71ec1a
......@@ -191,8 +191,10 @@ static int nft_synproxy_do_init(const struct nft_ctx *ctx,
if (err)
goto nf_ct_failure;
err = nf_synproxy_ipv6_init(snet, ctx->net);
if (err)
if (err) {
nf_synproxy_ipv4_fini(snet, ctx->net);
goto nf_ct_failure;
}
break;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册