Merge pull request #2640 from AdmiralCurtiss/real-wiimote-crash-fix

WiimoteReal: Fix crash when switching a real Wiimote to a different slot or type during emulation.
This commit is contained in:
Jules Blok 2015-06-26 20:33:50 +02:00
commit cff6d9f922
1 changed files with 6 additions and 3 deletions

View File

@ -484,10 +484,13 @@ void WiimoteScanner::ThreadFunc()
}
bool Wiimote::Connect()
{
if (!m_run_thread.load())
{
m_thread_ready.store(false);
StartThread();
WaitReady();
}
return IsConnected();
}