X-Git-Url: https://git.saurik.com/apple/libpthread.git/blobdiff_plain/215aeb0310146fee62c0f2602966571180f8eb63..964d3577b041867f776d8eb940bf4a1108ffb97c:/kern/kern_synch.c diff --git a/kern/kern_synch.c b/kern/kern_synch.c index ca75f6f..7136912 100644 --- a/kern/kern_synch.c +++ b/kern/kern_synch.c @@ -68,7 +68,6 @@ #include #include #include -#include //#include #include #include @@ -1609,6 +1608,7 @@ ksyn_wqfind(user_addr_t uaddr, uint32_t mgen, uint32_t ugen, uint32_t sgen, int pthread_list_lock(); res = ksyn_wq_hash_lookup(uaddr, current_proc(), flags, &kwq, &hashptr, &object, &offset); if (res != 0) { + pthread_list_unlock(); break; } if (kwq == NULL && nkwq == NULL) { @@ -1679,9 +1679,9 @@ ksyn_wqfind(user_addr_t uaddr, uint32_t mgen, uint32_t ugen, uint32_t sgen, int kwq->kw_dropcount++; } } + pthread_list_unlock(); break; } - pthread_list_unlock(); if (kwqp != NULL) { *kwqp = kwq; }