Skip to content

Commit 9d817bc

Browse files
committed
Merge branch 'master' into swrenderer
2 parents 15c3154 + b166042 commit 9d817bc

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

Diff for: Sources/Core/Thread.cpp

+5-2
Original file line numberDiff line numberDiff line change
@@ -144,10 +144,13 @@ namespace spades {
144144
}
145145

146146
void Thread::Quited() {
147-
AutoLocker locker(&lock);
147+
lock.Lock();
148148
threadInfo = NULL;
149-
if(autoDelete)
149+
if(autoDelete) {
150150
delete this;
151+
return;
152+
}
153+
lock.Unlock();
151154
}
152155

153156
void Thread::Run() {

0 commit comments

Comments
 (0)