diff --git a/src/threading/Queue.h b/src/threading/Queue.h index 4ca8f9cd92..4393cd6737 100644 --- a/src/threading/Queue.h +++ b/src/threading/Queue.h @@ -170,7 +170,10 @@ inline T Queue::Get() return 0; } else if ( messages[read_ptr].empty() ) + { + safe_unlock(&mutex[read_ptr]); return 0; + } T data = messages[read_ptr].front(); messages[read_ptr].pop();