commit | e86e5a07485bc0f33103004594a28882c028e7af | [log] [tgz] |
---|---|---|
author | wdenk <wdenk> | Sun Oct 17 21:12:06 2004 +0000 |
committer | wdenk <wdenk> | Sun Oct 17 21:12:06 2004 +0000 |
tree | b3f2496049f2e8f82676372d840bc10bf077de44 | |
parent | 8b74bf31fe57edfc502f94e905977304eac943ca [diff] [blame] |
Code cleanup for GCC-3.3.x compilers
diff --git a/common/usb.c b/common/usb.c index 1bb9438..4136f8d 100644 --- a/common/usb.c +++ b/common/usb.c
@@ -925,7 +925,9 @@ } descriptor = (struct usb_hub_descriptor *)buffer; - if (descriptor->bLength > USB_BUFSIZ) { + /* silence compiler warning if USB_BUFSIZ is > 256 [= sizeof(char)] */ + i = descriptor->bLength; + if (i > USB_BUFSIZ) { USB_HUB_PRINTF("usb_hub_configure: failed to get hub descriptor - too long: %d\N", descriptor->bLength); return -1;