Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=e2fddf5e96df4ac26f2e9ce63053d51cdf3cfe1e
Commit:     e2fddf5e96df4ac26f2e9ce63053d51cdf3cfe1e
Parent:     433d49c3bb14b8a2351fe97df8359e4ad0de4c7c
Author:     Daniel Lezcano <[EMAIL PROTECTED]>
AuthorDate: Fri Dec 7 00:44:29 2007 -0800
Committer:  David S. Miller <[EMAIL PROTECTED]>
CommitDate: Mon Jan 28 14:56:47 2008 -0800

    [IPV6]: Make af_inet6 to check ip6_route_init return value.
    
    The af_inet6 initialization function does not check the return code of
    the route initilization, so if something goes wrong, the protocol
    initialization will continue anyway.  This patch takes into account
    the modification made in the different route's initialization
    subroutines to check the return value and to make the protocol
    initialization to fail.
    
    Signed-off-by: Daniel Lezcano <[EMAIL PROTECTED]>
    Acked-by: Benjamin Thery <[EMAIL PROTECTED]>
    Signed-off-by: David S. Miller <[EMAIL PROTECTED]>
---
 net/ipv6/af_inet6.c |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)

diff --git a/net/ipv6/af_inet6.c b/net/ipv6/af_inet6.c
index 64135e2..5ab8ba7 100644
--- a/net/ipv6/af_inet6.c
+++ b/net/ipv6/af_inet6.c
@@ -849,7 +849,9 @@ static int __init inet6_init(void)
        if (if6_proc_init())
                goto proc_if6_fail;
 #endif
-       ip6_route_init();
+       err = ip6_route_init();
+       if (err)
+               goto ip6_route_fail;
        ip6_flowlabel_init();
        err = addrconf_init();
        if (err)
@@ -874,6 +876,7 @@ out:
 addrconf_fail:
        ip6_flowlabel_cleanup();
        ip6_route_cleanup();
+ip6_route_fail:
 #ifdef CONFIG_PROC_FS
        if6_proc_exit();
 proc_if6_fail:
@@ -904,6 +907,7 @@ icmp_fail:
        cleanup_ipv6_mibs();
 out_unregister_sock:
        sock_unregister(PF_INET6);
+       rtnl_unregister_all(PF_INET6);
 out_unregister_raw_proto:
        proto_unregister(&rawv6_prot);
 out_unregister_udplite_proto:
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to