Correct a buffer overflow in HID report parsing which stopped some mice from working. Also correct some other possible buffer overflows and a parsing error or two.