diff options
author | John W. Linville <linville@tuxdriver.com> | 2012-08-10 14:41:38 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2012-08-10 14:41:38 -0400 |
commit | bbf2e65258302c42d74fd53b3d92d6d8f03aaeff (patch) | |
tree | ea5c85947305d81e3b2a2b0cc4c2b036fdfb870e /net/bluetooth/smp.c | |
parent | 50e2a30cf6fcaeb2d27360ba614dd169a10041c5 (diff) | |
parent | 2096ae6ca647302d50a68aa36cb66a00e7dfac70 (diff) | |
download | op-kernel-dev-bbf2e65258302c42d74fd53b3d92d6d8f03aaeff.zip op-kernel-dev-bbf2e65258302c42d74fd53b3d92d6d8f03aaeff.tar.gz |
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/bluetooth/bluetooth
Diffstat (limited to 'net/bluetooth/smp.c')
-rw-r--r-- | net/bluetooth/smp.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/net/bluetooth/smp.c b/net/bluetooth/smp.c index 16ef0dc..901a616 100644 --- a/net/bluetooth/smp.c +++ b/net/bluetooth/smp.c @@ -579,8 +579,11 @@ static u8 smp_cmd_pairing_req(struct l2cap_conn *conn, struct sk_buff *skb) if (!test_and_set_bit(HCI_CONN_LE_SMP_PEND, &conn->hcon->flags)) smp = smp_chan_create(conn); + else + smp = conn->smp_chan; - smp = conn->smp_chan; + if (!smp) + return SMP_UNSPECIFIED; smp->preq[0] = SMP_CMD_PAIRING_REQ; memcpy(&smp->preq[1], req, sizeof(*req)); |