Commit 9abdcf6b authored by Yuri Gushin's avatar Yuri Gushin Committed by David S. Miller

[NETFILTER]: xt_tcpudp: fix double unregistration in error path

"xt_unregister_match(AF_INET, &tcp_matchstruct)" is called twice,
leaving "udp_matchstruct" registered, in case of a failure in the
registration of the udp6 structure.
Signed-off-by: default avatarYuri Gushin <yuri@ecl-labs.org>
Signed-off-by: default avatarPatrick McHardy <kaber@trash.net>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 40a839fd
......@@ -260,7 +260,7 @@ static int __init xt_tcpudp_init(void)
return ret;
out_unreg_udp:
xt_unregister_match(&tcp_matchstruct);
xt_unregister_match(&udp_matchstruct);
out_unreg_tcp6:
xt_unregister_match(&tcp6_matchstruct);
out_unreg_tcp:
......
Markdown is supported
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