attempt to fix a thread bug when starting a game

This commit is contained in:
Mark Vejvoda
2013-06-01 06:28:03 +00:00
parent 7f88d866c1
commit 22eb5cc4d4
3 changed files with 19 additions and 14 deletions

View File

@@ -427,6 +427,19 @@ bool SimpleTaskThread::canShutdown(bool deleteSelfIfShutdownDelayed) {
return ret;
}
bool SimpleTaskThread::getSimpleTaskInterfaceValid() {
string mutexOwnerId1 = string(__FILE__) + string("_") + intToStr(__LINE__);
MutexSafeWrapper safeMutex1(&mutexSimpleTaskInterfaceValid,mutexOwnerId1);
return this->simpleTaskInterfaceValid;
}
void SimpleTaskThread::setSimpleTaskInterfaceValid(bool value) {
string mutexOwnerId1 = string(__FILE__) + string("_") + intToStr(__LINE__);
MutexSafeWrapper safeMutex1(&mutexSimpleTaskInterfaceValid,mutexOwnerId1);
this->simpleTaskInterfaceValid = value;
}
void SimpleTaskThread::execute() {
if(SystemFlags::VERBOSE_MODE_ENABLED) printf("In [%s::%s Line: %d]\n",__FILE__,__FUNCTION__,__LINE__);
void *ptr_cpy = this->ptr;