summaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorNeil Horman <nhorman@redhat.com>2005-04-28 11:59:49 -0700
committerDavid S. Miller <davem@davemloft.net>2005-04-28 11:59:49 -0700
commit5e6bc34f86e450ff14c4817902d66aa9c786bc06 (patch)
tree1a4db9bc742bcfd7368caf79b9c751f49b4c667b /net
parentb9b9e10f180fa63b55b93412edf0ab9648675646 (diff)
downloadop-kernel-dev-5e6bc34f86e450ff14c4817902d66aa9c786bc06.zip
op-kernel-dev-5e6bc34f86e450ff14c4817902d66aa9c786bc06.tar.gz
[SCTP] Fix bug in sctp_init() error handling code.
Signed-off-by: Neil Horman <nhorman@redhat.com> Signed-off-by: Sridhar Samudrala <sri@us.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r--net/sctp/protocol.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/net/sctp/protocol.c b/net/sctp/protocol.c
index b9813cf..23c85a2 100644
--- a/net/sctp/protocol.c
+++ b/net/sctp/protocol.c
@@ -1159,8 +1159,6 @@ SCTP_STATIC __init int sctp_init(void)
status = 0;
out:
return status;
-err_add_protocol:
- proto_unregister(&sctp_prot);
err_ctl_sock_init:
sctp_v6_exit();
err_v6_init:
@@ -1188,6 +1186,8 @@ err_bucket_cachep:
inet_del_protocol(&sctp_protocol, IPPROTO_SCTP);
inet_unregister_protosw(&sctp_seqpacket_protosw);
inet_unregister_protosw(&sctp_stream_protosw);
+err_add_protocol:
+ proto_unregister(&sctp_prot);
goto out;
}
OpenPOWER on IntegriCloud