netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] Fix order in inet_init failure path.
@ 2006-09-26 14:17 Olaf Kirch
  2006-09-27 23:33 ` David Miller
  0 siblings, 1 reply; 2+ messages in thread
From: Olaf Kirch @ 2006-09-26 14:17 UTC (permalink / raw)
  To: netdev

This is just a minor buglet I came across by accident - when inet_init
fails to register raw_prot, it jumps to out_unregister_udp_proto which
should unregister UDP _and_ TCP.

Signed-off-by: Olaf Kirch <okir@suse.de>

 net/ipv4/af_inet.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

Index: build/net/ipv4/af_inet.c
===================================================================
--- build.orig/net/ipv4/af_inet.c
+++ build/net/ipv4/af_inet.c
@@ -1345,10 +1345,10 @@ static int __init inet_init(void)
 	rc = 0;
 out:
 	return rc;
-out_unregister_tcp_proto:
-	proto_unregister(&tcp_prot);
 out_unregister_udp_proto:
 	proto_unregister(&udp_prot);
+out_unregister_tcp_proto:
+	proto_unregister(&tcp_prot);
 	goto out;
 }
 

-- 
Olaf Kirch   |  --- o --- Nous sommes du soleil we love when we play
okir@suse.de |    / | \   sol.dhoop.naytheet.ah kin.ir.samse.qurax

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] Fix order in inet_init failure path.
  2006-09-26 14:17 [PATCH] Fix order in inet_init failure path Olaf Kirch
@ 2006-09-27 23:33 ` David Miller
  0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2006-09-27 23:33 UTC (permalink / raw)
  To: okir; +Cc: netdev

From: Olaf Kirch <okir@suse.de>
Date: Tue, 26 Sep 2006 16:17:09 +0200

> This is just a minor buglet I came across by accident - when inet_init
> fails to register raw_prot, it jumps to out_unregister_udp_proto which
> should unregister UDP _and_ TCP.
> 
> Signed-off-by: Olaf Kirch <okir@suse.de>

Applied, thanks Olaf.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2006-09-27 23:33 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-09-26 14:17 [PATCH] Fix order in inet_init failure path Olaf Kirch
2006-09-27 23:33 ` David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).