mirror of
https://git.kernel.org/pub/scm/bluetooth/bluez.git
synced 2024-11-26 21:54:33 +08:00
android/hidhost: Fix miscalculation of get report event notification length
Event length is size of struct + data len (if any). It is miscalulated.
This commit is contained in:
parent
ce7eb5d0c5
commit
9d30a5a539
@ -371,7 +371,7 @@ static void bt_hid_notify_get_report(struct hid_device *dev, uint8_t *buf,
|
||||
ba2str(&dev->dst, address);
|
||||
DBG("device %s", address);
|
||||
|
||||
ev_len = sizeof(*ev) + sizeof(struct hal_ev_hidhost_get_report) + 1;
|
||||
ev_len = sizeof(*ev);
|
||||
|
||||
if (!((buf[0] == (HID_MSG_DATA | HID_DATA_TYPE_INPUT)) ||
|
||||
(buf[0] == (HID_MSG_DATA | HID_DATA_TYPE_OUTPUT)) ||
|
||||
|
Loading…
Reference in New Issue
Block a user