Changeset 3ee48f2 in mainline for uspace/lib/usb/src/hidparser.c
- Timestamp:
- 2011-01-28T15:55:55Z (14 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- c113056
- Parents:
- 2b96463 (diff), 11797d5 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/usb/src/hidparser.c
r2b96463 r3ee48f2 35 35 #include <usb/classes/hidparser.h> 36 36 #include <errno.h> 37 #include <stdio.h> 37 38 38 39 /** Parse HID report descriptor. … … 120 121 item.logical_max = 255; 121 122 122 if (size != 8){123 return -1;123 if (size != 8) { 124 return ERANGE; 124 125 } 125 126 126 127 uint8_t keys[6]; 127 for (i=item.offset; i<item.count; i++) {128 keys[i -2] = data[i];128 for (i = 0; i < item.count; i++) { 129 keys[i] = data[i + item.offset]; 129 130 } 130 131
Note:
See TracChangeset
for help on using the changeset viewer.