]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - net/unix/af_unix.c
net: Make sure BHs are disabled in sock_prot_inuse_add()
[linux-2.6-omap-h63xx.git] / net / unix / af_unix.c
index e1ca8f744ca5d1fe457d043dcf72a53f6aa98ccb..a45a9f7369ed751206f662932051463f6fbf5c52 100644 (file)
@@ -361,7 +361,9 @@ static void unix_sock_destructor(struct sock *sk)
                unix_release_addr(u->addr);
 
        atomic_dec(&unix_nr_socks);
+       local_bh_disable();
        sock_prot_inuse_add(sock_net(sk), sk->sk_prot, -1);
+       local_bh_enable();
 #ifdef UNIX_REFCNT_DEBUG
        printk(KERN_DEBUG "UNIX %p is destroyed, %d are still alive.\n", sk,
                atomic_read(&unix_nr_socks));