summaryrefslogtreecommitdiffstats
path: root/net/bluetooth/hci_core.c
diff options
context:
space:
mode:
authorAndrei Emeltchenko2012-05-23 10:31:20 +0200
committerJohan Hedberg2012-06-05 05:34:06 +0200
commit9b3b44604ac8e06d299718c5d0fa0b91b675ae0b (patch)
treeb079fbe2b97d297f19c5d4c24560169157ac3db9 /net/bluetooth/hci_core.c
parentBluetooth: Rename HCI_QUIRK_NO_RESET to HCI_QUIRK_RESET_ON_CLOSE (diff)
downloadkernel-qcow2-linux-9b3b44604ac8e06d299718c5d0fa0b91b675ae0b.tar.gz
kernel-qcow2-linux-9b3b44604ac8e06d299718c5d0fa0b91b675ae0b.tar.xz
kernel-qcow2-linux-9b3b44604ac8e06d299718c5d0fa0b91b675ae0b.zip
Bluetooth: Use defined link key size
Remove magic number with defined link key size. Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Diffstat (limited to 'net/bluetooth/hci_core.c')
-rw-r--r--net/bluetooth/hci_core.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/bluetooth/hci_core.c b/net/bluetooth/hci_core.c
index 0ed4edf0f77b..027257d4b52a 100644
--- a/net/bluetooth/hci_core.c
+++ b/net/bluetooth/hci_core.c
@@ -1291,7 +1291,7 @@ int hci_add_link_key(struct hci_dev *hdev, struct hci_conn *conn, int new_key,
}
bacpy(&key->bdaddr, bdaddr);
- memcpy(key->val, val, 16);
+ memcpy(key->val, val, HCI_LINK_KEY_SIZE);
key->pin_len = pin_len;
if (type == HCI_LK_CHANGED_COMBINATION)