YAML does support hex as long as it's 0x-prefixed. The comment here (probably)
dates from an in-development version of libinput-record that used JSON.
Anyway, let's print the HID report descriptor as hex because that's the common
format for it.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
while ((len = read(fd, buf, sizeof(buf))) > 0) {
for (int i = 0; i < len; i++) {
- /* YAML requires decimal */
- iprintf(dev->fp, I_NONE, "%s%u", sep, buf[i]);
+ iprintf(dev->fp, I_NONE, "%s0x%02x", sep, buf[i]);
sep = ", ";
}
}