diff options
author | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-04-10 20:23:36 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-04-10 20:23:36 -0400 |
commit | e676853c8c3f77166c03f1eea7dab6e854eeb819 (patch) | |
tree | 0cbd6fda6a8cdc568b3b67fe188c5ca45bb8db59 /drivers | |
parent | 8bd51cce98aa80ff8b56d34a0e48316c5f887818 (diff) | |
parent | 8da7d1bae512aee155ef02f7ab1266358842e1fd (diff) |
Merge branch 'upstream-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid
* 'upstream-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid:
HID: Do not discard truncated input reports
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/hid/hid-core.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/hid/hid-core.c b/drivers/hid/hid-core.c index 67f3347afcf3..1cca32f46947 100644 --- a/drivers/hid/hid-core.c +++ b/drivers/hid/hid-core.c | |||
@@ -969,7 +969,7 @@ int hid_input_report(struct hid_device *hid, int type, u8 *data, int size, int i | |||
969 | 969 | ||
970 | if (size < rsize) { | 970 | if (size < rsize) { |
971 | dbg("report %d is too short, (%d < %d)", report->id, size, rsize); | 971 | dbg("report %d is too short, (%d < %d)", report->id, size, rsize); |
972 | return -1; | 972 | memset(data + size, 0, rsize - size); |
973 | } | 973 | } |
974 | 974 | ||
975 | if ((hid->claimed & HID_CLAIMED_HIDDEV) && hid->hiddev_report_event) | 975 | if ((hid->claimed & HID_CLAIMED_HIDDEV) && hid->hiddev_report_event) |