From: Martin Ling Date: Sun, 22 Dec 2013 17:10:57 +0000 (+0000) Subject: Windows usb: Unlock mutex when shutting down wait thread. X-Git-Tag: libsigrok-0.3.0~418 X-Git-Url: https://sigrok.org/gitaction?a=commitdiff_plain;h=b5328e1dfaf8a03ce503ab89abed0d83c58a7bb2;p=libsigrok.git Windows usb: Unlock mutex when shutting down wait thread. --- diff --git a/hardware/common/usb.c b/hardware/common/usb.c index f99d82db..64f887de 100644 --- a/hardware/common/usb.c +++ b/hardware/common/usb.c @@ -304,6 +304,7 @@ SR_PRIV int usb_source_remove(struct sr_context *ctx) { #ifdef _WIN32 ctx->usb_thread_running = FALSE; + g_mutex_unlock(&ctx->usb_mutex); libusb_unlock_events(ctx->libusb_ctx); g_thread_join(ctx->usb_thread); g_mutex_clear(&ctx->usb_mutex);