u/sink: Add some comments

This commit is contained in:
Moses Turner 2022-03-05 08:14:33 -06:00 committed by Jakob Bornecrantz
parent 37f0c901d2
commit 7235b6a45a

View file

@ -52,6 +52,8 @@ struct u_sink_queue
pthread_t thread;
pthread_mutex_t mutex;
//! So we can wake the mainloop up
pthread_cond_t cond;
//! Should we keep running.
@ -141,7 +143,7 @@ queue_mainloop(void *ptr)
pthread_cond_wait(&q->cond, &q->mutex);
}
// Where we woken up to turn off.
// In this case, queue_break_apart woke us up to turn us off.
if (!q->running) {
break;
}