1 diff --git a/libusb/libusb.h b/libusb/libusb.h
2 index e8e1201..15bd0d5 100644
9 +// Disable warning 4200 for [0].
10 +#pragma warning(push)
11 +#pragma warning(disable: 4200)
15 /* on MS environments, the inline keyword is available in C++ only */
16 #if !defined(__cplusplus)
17 #define inline __inline
18 @@ -1938,4 +1944,8 @@ void LIBUSB_CALL libusb_hotplug_deregister_callback(libusb_context *ctx,
27 diff --git a/libusb/os/threads_posix.c b/libusb/os/threads_posix.c
28 index 9769f58..46f6db7 100644
29 --- a/libusb/os/threads_posix.c
30 +++ b/libusb/os/threads_posix.c
34 #if defined(__linux__) || defined(__OpenBSD__)
35 -# if defined(__linux__)
41 # include <sys/syscall.h>
42 #elif defined(__APPLE__)
43 diff --git a/libusb/os/windows_usb.c b/libusb/os/windows_usb.c
44 index 63357b1..51ce55d 100644
45 --- a/libusb/os/windows_usb.c
46 +++ b/libusb/os/windows_usb.c
47 @@ -2142,6 +2142,7 @@ static int windows_handle_events(struct libusb_context *ctx, struct pollfd *fds,
48 windows_handle_callback(transfer, io_result, io_size);
50 usbi_err(ctx, "could not find a matching transfer for fd %x", fds[i]);
51 + usbi_mutex_unlock(&ctx->open_devs_lock);
52 return LIBUSB_ERROR_NOT_FOUND;