]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - net/irda/af_irda.c
Merge branch 'audit.b63' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/audit...
[karo-tx-linux.git] / net / irda / af_irda.c
index 3eb5bcc75f99083eb971b93eddbb967d704ad81a..cb762c8723ea7a90f98b9e34074d98bc3b716742 100644 (file)
@@ -913,9 +913,6 @@ static int irda_accept(struct socket *sock, struct socket *newsock, int flags)
        /* Clean up the original one to keep it in listen state */
        irttp_listen(self->tsap);
 
-       /* Wow ! What is that ? Jean II */
-       skb->sk = NULL;
-       skb->destructor = NULL;
        kfree_skb(skb);
        sk->sk_ack_backlog--;
 
@@ -1762,7 +1759,8 @@ static int irda_ioctl(struct socket *sock, unsigned int cmd, unsigned long arg)
        switch (cmd) {
        case TIOCOUTQ: {
                long amount;
-               amount = sk->sk_sndbuf - atomic_read(&sk->sk_wmem_alloc);
+
+               amount = sk->sk_sndbuf - sk_wmem_alloc_get(sk);
                if (amount < 0)
                        amount = 0;
                if (put_user(amount, (unsigned int __user *)arg))