mirror of https://github.com/nymea/nymea-gpio
Fix deadlock in gpiomonitor
parent
5623e9ae84
commit
6942124a97
|
|
@ -219,8 +219,12 @@ void GpioMonitor::run()
|
|||
}
|
||||
|
||||
// Check if we should stop the thread
|
||||
QMutexLocker stopLocker(&m_stopMutex);
|
||||
if (m_stop) break;
|
||||
m_stopMutex.lock();
|
||||
if (m_stop) {
|
||||
m_stopMutex.unlock();
|
||||
break;
|
||||
}
|
||||
m_stopMutex.unlock();
|
||||
|
||||
// No interrupt occured
|
||||
if (rc == 0)
|
||||
|
|
|
|||
Loading…
Reference in New Issue