diff options
Diffstat (limited to 'usb_keyboard.c')
-rw-r--r-- | usb_keyboard.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/usb_keyboard.c b/usb_keyboard.c index 6b5edec..eed1b88 100644 --- a/usb_keyboard.c +++ b/usb_keyboard.c @@ -84,7 +84,7 @@ uint8_t const *tud_hid_descriptor_report_cb(uint8_t index) { static uint8_t const *reports[] = { hid_report_descriptor_keyboard, }; - if (index >= sizeof reports / sizeof reports[0]) + if (index >= TU_ARRAY_SIZE(reports)) return NULL; return reports[index]; } |