]> git.karo-electronics.de Git - karo-tx-linux.git/commit
net: fix a race in sock_queue_err_skb()
authorEric Dumazet <eric.dumazet@gmail.com>
Fri, 6 Apr 2012 08:49:10 +0000 (10:49 +0200)
committerBen Hutchings <ben@decadent.org.uk>
Fri, 11 May 2012 12:14:21 +0000 (13:14 +0100)
commit8a0885b2113dfe7d1fb4f981a3d3c712ad90619c
tree03e63dc9e197b488f2c62003c7fa1bb79dffd3e8
parentd6465c3d0237438855ba4adfbdee210d3220ca77
net: fix a race in sock_queue_err_skb()

[ Upstream commit 110c43304db6f06490961529536c362d9ac5732f ]

As soon as an skb is queued into socket error queue, another thread
can consume it, so we are not allowed to reference skb anymore, or risk
use after free.

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
net/core/skbuff.c