1
0
mirror of https://github.com/mpv-player/mpv synced 2024-12-22 06:42:03 +00:00

dispatch: add an assert()

This commit is contained in:
wm4 2018-05-05 20:19:34 +02:00 committed by sfan5
parent fae9d7744c
commit 58479906d8

View File

@ -274,6 +274,7 @@ void mp_dispatch_queue_process(struct mp_dispatch_queue *queue, double timeout)
// while the dispatch item is processed.
// At the same time, we must prevent other threads from returning
// from mp_dispatch_lock(), which is done by locked=true.
assert(!queue->locked);
queue->locked = true;
pthread_mutex_unlock(&queue->lock);