sysctl: net: call unregister_net_sysctl_table where needed
authorLucian Adrian Grijincu <lucian.grijincu@gmail.com>
Sun, 1 May 2011 01:44:01 +0000 (01:44 +0000)
committerDavid S. Miller <davem@davemloft.net>
Mon, 2 May 2011 23:12:14 +0000 (16:12 -0700)
ctl_table_headers registered with register_net_sysctl_table should
have been unregistered with the equivalent unregister_net_sysctl_table

Signed-off-by: Lucian Adrian Grijincu <lucian.grijincu@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/devinet.c
net/ipv6/addrconf.c

index 5345b0bee6df816858c1424d0ccb50988d133aa2..cd9ca0811cfaf30a179db870bfe628d4d0261a2e 100644 (file)
@@ -1680,7 +1680,7 @@ static void __devinet_sysctl_unregister(struct ipv4_devconf *cnf)
                return;
 
        cnf->sysctl = NULL;
-       unregister_sysctl_table(t->sysctl_header);
+       unregister_net_sysctl_table(t->sysctl_header);
        kfree(t->dev_name);
        kfree(t);
 }
index 1493534116df489b8a41411face52d2b06279928..a7bda0757053278e58218766df54cb49fac100d6 100644 (file)
@@ -4537,7 +4537,7 @@ static void __addrconf_sysctl_unregister(struct ipv6_devconf *p)
 
        t = p->sysctl;
        p->sysctl = NULL;
-       unregister_sysctl_table(t->sysctl_header);
+       unregister_net_sysctl_table(t->sysctl_header);
        kfree(t->dev_name);
        kfree(t);
 }