Skip to content
Commit ac088a88 authored by Cong Wang's avatar Cong Wang Committed by Pablo Neira Ayuso
Browse files

netfilter: conntrack: fix error path in nf_conntrack_pernet_init()



When nf_ct_netns_get() fails, it should clean up itself,
its caller doesn't need to call nf_conntrack_fini_net().

nf_conntrack_init_net() is called after registering sysctl
and proc, so its cleanup function should be called before
unregistering sysctl and proc.

Fixes: ba3fbe66 ("netfilter: nf_conntrack: provide modparam to always register conntrack hooks")
Fixes: b884fa46 ("netfilter: conntrack: unify sysctl handling")
Reported-and-tested-by: default avatar <syzbot+fcee88b2d87f0539dfe9@syzkaller.appspotmail.com>
Signed-off-by: default avatarCong Wang <xiyou.wangcong@gmail.com>
Signed-off-by: default avatarPablo Neira Ayuso <pablo@netfilter.org>
parent dd03b1ad
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment