summaryrefslogtreecommitdiffstats
path: root/net/nfc/rawsock.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2012-06-28 16:58:09 -0700
committerDavid S. Miller <davem@davemloft.net>2012-06-28 16:58:09 -0700
commitca33c00fff12b15428003b7b0423b313190ef03a (patch)
tree379c58de3d8a04243e1a52f61d1eb22fa2c52f53 /net/nfc/rawsock.c
parent9740e001932f59ee007d13ee3f39bb1b61086651 (diff)
parentde03309bd209b6fb025e9359266e0cbb441f7441 (diff)
downloadlinux-ca33c00fff12b15428003b7b0423b313190ef03a.tar.gz
linux-ca33c00fff12b15428003b7b0423b313190ef03a.tar.bz2
linux-ca33c00fff12b15428003b7b0423b313190ef03a.zip
Merge branch 'for-davem' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless
John Linville says: ==================== Amitkumar Karwar gives us two mwifiex fixes: one fixes some skb manipulations when handling some event messages; and another that does some similar fixing on an error path. Avinash Patil gives us a fix for for a memory leak in mwifiex. Dan Rosenberg offers an NFC NCI fix to enforce some message length limits to prevent buffer overflows. Eliad Peller provides a mac80211 fix to prevent some frames from being built with an invalid BSSID. Eric Dumazet sends an NFC fix to prevent a BUG caused by a NULL pointer dereference. Felix Fietkau has an ath9k fix for a regression causing LEAP-authenticated connection failures. Johannes Berg provides an iwlwifi fix that eliminates some log SPAM after an authentication/association timeout. He also provides a mac80211 fix to prevent incorrectly addressing certain action frames (and in so doing, to comply with the 802.11 specs). Larry Finger provides a few USB IDs for the rtl8192cu driver -- should be harmless. Panayiotis Karabassis provices a one-liner to fix kernel bug 42903 (a system freeze). Randy Dunlap provides a one-line Kconfig change to prevent build failures with some configurations. Stone Piao provides an mwifiex sequence numbering fix and a fix to prevent mwifiex from attempting to include eapol frames in an aggregation frame. Finally, Tom Hughes provides an ath9k fix for a NULL pointer dereference. ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/nfc/rawsock.c')
-rw-r--r--net/nfc/rawsock.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/net/nfc/rawsock.c b/net/nfc/rawsock.c
index ec1134c9e07f..8b8a6a2b2bad 100644
--- a/net/nfc/rawsock.c
+++ b/net/nfc/rawsock.c
@@ -54,7 +54,10 @@ static int rawsock_release(struct socket *sock)
{
struct sock *sk = sock->sk;
- pr_debug("sock=%p\n", sock);
+ pr_debug("sock=%p sk=%p\n", sock, sk);
+
+ if (!sk)
+ return 0;
sock_orphan(sk);
sock_put(sk);