Add missing mutex unlock in failure case.
Differential Revision: https://reviews.freebsd.org/D23430 Submitted by: cem Reported by: Coverity Coverity CID: 1368773 MFC after: 3 days Sponsored by: Mellanox Technologies
This commit is contained in:
parent
e48813009c
commit
cca46c5e69
@ -123,8 +123,10 @@ libusb_hotplug_scan(void *arg)
|
|||||||
TAILQ_INIT(&hotplug_devs);
|
TAILQ_INIT(&hotplug_devs);
|
||||||
|
|
||||||
if (ctx->hotplug_handler != NO_THREAD) {
|
if (ctx->hotplug_handler != NO_THREAD) {
|
||||||
if (libusb_hotplug_enumerate(ctx, &hotplug_devs) < 0)
|
if (libusb_hotplug_enumerate(ctx, &hotplug_devs) < 0) {
|
||||||
|
HOTPLUG_UNLOCK(ctx);
|
||||||
continue;
|
continue;
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
do_loop = 0;
|
do_loop = 0;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user