Probably fix crash on exit reported in #8022

This commit is contained in:
Henrik Rydgard 2015-10-04 16:12:03 +02:00
parent 490d8be4df
commit 41efe18bba

View file

@ -107,7 +107,9 @@ void ProcessWorkQueueOnThreadWhile(PrioritizedWorkQueue *wq) {
void StopProcessingWorkQueue(PrioritizedWorkQueue *wq) {
wq->Stop();
workThread->join();
delete workThread;
if (workThread) {
workThread->join();
delete workThread;
}
workThread = 0;
}