examples: fix 3 compiler warnings
authorLudovic Rousseau <ludovic.rousseau@free.fr>
Sat, 27 Feb 2016 16:52:05 +0000 (17:52 +0100)
committerLudovic Rousseau <ludovic.rousseau@free.fr>
Wed, 2 Mar 2016 15:07:00 +0000 (16:07 +0100)
fxload.c:202:17: warning: comparison of integers of different signs: 'int' and
      'unsigned long' [-Wsign-compare]
  ...for (j=0; j<ARRAYSIZE(known_device); j++) {
               ~^~~~~~~~~~~~~~~~~~~~~~~~
fxload.c:222:12: warning: comparison of integers of different signs: 'int' and
      'unsigned long' [-Wsign-compare]
                                        if (j < ARRAYSIZE(known_device)) {
                                            ~ ^ ~~~~~~~~~~~~~~~~~~~~~~~
fxload.c:263:13: warning: comparison of integers of different signs: 'int' and
      'unsigned long' [-Wsign-compare]
        for (i=0; i<ARRAYSIZE(path); i++) {
                  ~^~~~~~~~~~~~~~~~

Signed-off-by: Ludovic Rousseau <ludovic.rousseau@free.fr>
examples/fxload.c
libusb/version_nano.h

index 5dff736..5aa5226 100644 (file)
@@ -89,7 +89,8 @@ int main(int argc, char*argv[])
        const char *fx_name[FX_TYPE_MAX] = FX_TYPE_NAMES;
        const char *ext, *img_name[] = IMG_TYPE_NAMES;
        int fx_type = FX_TYPE_UNDEFINED, img_type[ARRAYSIZE(path)];
-       int i, j, opt, status;
+       int opt, status;
+       unsigned int i, j;
        unsigned vid = 0, pid = 0;
        unsigned busnum = 0, devaddr = 0, _busnum, _devaddr;
        libusb_device *dev, **devs;
index 34110b0..340ae63 100644 (file)
@@ -1 +1 @@
-#define LIBUSB_NANO 11086
+#define LIBUSB_NANO 11087