168 |
pThread->mutex.Unlock(); |
pThread->mutex.Unlock(); |
169 |
} |
} |
170 |
|
|
171 |
|
#ifdef __APPLE__ |
172 |
int InstrumentManagerThread::StopThread() { |
int InstrumentManagerThread::StopThread() { |
173 |
// This is a fix for Mac OS X, where SignalStopThread doesn't |
// This is a fix for Mac OS X, where SignalStopThread doesn't |
174 |
// wake up a thread waiting for a condition variable. |
// wake up a thread waiting for a condition variable. |
176 |
conditionJobsLeft.Set(true); // wake thread |
conditionJobsLeft.Set(true); // wake thread |
177 |
return Thread::StopThread(); // then wait for it to cancel |
return Thread::StopThread(); // then wait for it to cancel |
178 |
} |
} |
179 |
|
#endif |
180 |
|
|
181 |
} // namespace LinuxSampler |
} // namespace LinuxSampler |