Core: fix compiler warning in libusb_setlocale()
authorLudovic Rousseau <ludovic.rousseau@gmail.com>
Wed, 19 Jun 2013 11:21:06 +0000 (13:21 +0200)
committerHans de Goede <hdegoede@redhat.com>
Wed, 19 Jun 2013 14:12:35 +0000 (16:12 +0200)
Hello,

A small patch for:

strerror.c: In function 'libusb_setlocale':
strerror.c:148: warning: comparison between signed and unsigned
strerror.c:152: warning: comparison between signed and unsigned

--
 Dr. Ludovic Rousseau

From a4144845845cd0a06fb9074ba2d6669ece3a5b1a Mon Sep 17 00:00:00 2001
From: Ludovic Rousseau <ludovic.rousseau+github@gmail.com>
Date: Wed, 19 Jun 2013 13:16:31 +0200
Subject: [PATCH] Core: fix compiler warning in libusb_setlocale()

strerror.c: In function 'libusb_setlocale':
strerror.c:148: warning: comparison between signed and unsigned
strerror.c:152: warning: comparison between signed and unsigned

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
libusb/strerror.c
libusb/version_nano.h

index dfb4863..aab82b6 100644 (file)
@@ -139,7 +139,7 @@ static const char* usbi_localized_errors[ARRAYSIZE(usbi_locale_supported)][LIBUS
 
 int API_EXPORTED libusb_setlocale(const char *locale)
 {
-       int i;
+       size_t i;
 
        if ( (locale == NULL) || (strlen(locale) < 2)
          || ((strlen(locale) > 2) && (locale[2] != '-') && (locale[2] != '_') && (locale[2] != '.')) )
index 1a7fc02..915debd 100644 (file)
@@ -1 +1 @@
-#define LIBUSB_NANO 10746
+#define LIBUSB_NANO 10747