summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPete Batard <pbatard@gmail.com>2010-10-05 12:53:31 +0100
committerPete Batard <pbatard@gmail.com>2010-10-05 12:53:31 +0100
commite0e7ffde567fac025dacd63b7eb7bd5ddb38ffd7 (patch)
tree21ce6280e164bb829a2d57edf85b42211207dce7
parentd4de93e6e93583f65d5d0ed535c836e1755a0329 (diff)
downloadlibusb-e0e7ffde567fac025dacd63b7eb7bd5ddb38ffd7.tar.gz
small fixup to be in check with proposed official
-rw-r--r--libusb/os/windows_usb.c2
-rw-r--r--libusb/os/windows_usb.h2
2 files changed, 2 insertions, 2 deletions
diff --git a/libusb/os/windows_usb.c b/libusb/os/windows_usb.c
index a18f6fa..d3709e4 100644
--- a/libusb/os/windows_usb.c
+++ b/libusb/os/windows_usb.c
@@ -1658,7 +1658,7 @@ static void windows_exit(void)
if (WaitForSingleObject(semaphore, INFINITE) != WAIT_OBJECT_0) {
CloseHandle(semaphore);
return;
- }
+ }
// Only works if exits and inits are balanced exactly
if (--concurrent_usage < 0) { // Last exit
diff --git a/libusb/os/windows_usb.h b/libusb/os/windows_usb.h
index b37fb56..dc90a64 100644
--- a/libusb/os/windows_usb.h
+++ b/libusb/os/windows_usb.h
@@ -78,7 +78,7 @@ extern char *_strdup(const char *strSource);
#define safe_strlen(str) ((str==NULL)?0:strlen(str))
#define safe_sprintf _snprintf
#define safe_unref_device(dev) do {if (dev != NULL) {libusb_unref_device(dev); dev = NULL;}} while(0)
-#define wchar_to_utf8_ms(wstr, str, len) WideCharToMultiByte(CP_UTF8, 0, wstr, -1, str, len, NULL, NULL)
+#define wchar_to_utf8_ms(wstr, str, strlen) WideCharToMultiByte(CP_UTF8, 0, wstr, -1, str, strlen, NULL, NULL)
inline void upperize(char* str) {
size_t i;
if (str == NULL) return;