Lines Matching refs:ctx_handler
246 err = (ctx->ctx_handler != NO_THREAD); in libusb_try_lock_events()
250 ctx->ctx_handler = pthread_self(); in libusb_try_lock_events()
260 if (ctx->ctx_handler == NO_THREAD) in libusb_lock_events()
261 ctx->ctx_handler = pthread_self(); in libusb_lock_events()
268 if (ctx->ctx_handler == pthread_self()) { in libusb_unlock_events()
269 ctx->ctx_handler = NO_THREAD; in libusb_unlock_events()
279 return (ctx->ctx_handler == pthread_self()); in libusb_event_handling_ok()
286 return (ctx->ctx_handler != NO_THREAD); in libusb_event_handler_active()
316 if (ctx->ctx_handler == NO_THREAD) in libusb_wait_for_event()
317 ctx->ctx_handler = pthread_self(); in libusb_wait_for_event()
337 if (ctx->ctx_handler == NO_THREAD) in libusb_wait_for_event()
338 ctx->ctx_handler = pthread_self(); in libusb_wait_for_event()