mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2024-11-14 13:27:45 -07:00
Merge pull request #8518 from stenzek/more-wiimote-reset-crashes
Core: Reset Wiimotes/rumble/memwatcher on emu thread
This commit is contained in:
commit
a980a39807
@ -289,15 +289,6 @@ void Stop() // - Hammertime!
|
||||
|
||||
g_video_backend->Video_ExitLoop();
|
||||
}
|
||||
|
||||
if (_CoreParameter.bWii)
|
||||
Wiimote::ResetAllWiimotes();
|
||||
|
||||
ResetRumble();
|
||||
|
||||
#ifdef USE_MEMORYWATCHER
|
||||
s_memory_watcher.reset();
|
||||
#endif
|
||||
}
|
||||
|
||||
void DeclareAsCPUThread()
|
||||
@ -374,6 +365,10 @@ static void CpuThread(const std::optional<std::string>& savestate_path, bool del
|
||||
// Enter CPU run loop. When we leave it - we are done.
|
||||
CPU::Run();
|
||||
|
||||
#ifdef USE_MEMORYWATCHER
|
||||
s_memory_watcher.reset();
|
||||
#endif
|
||||
|
||||
s_is_started = false;
|
||||
|
||||
if (_CoreParameter.bFastmem)
|
||||
@ -533,7 +528,12 @@ static void EmuThread(std::unique_ptr<BootParameters> boot, WindowSystemInfo wsi
|
||||
return;
|
||||
|
||||
if (init_wiimotes)
|
||||
{
|
||||
Wiimote::ResetAllWiimotes();
|
||||
Wiimote::Shutdown();
|
||||
}
|
||||
|
||||
ResetRumble();
|
||||
|
||||
Keyboard::Shutdown();
|
||||
Pad::Shutdown();
|
||||
|
Loading…
Reference in New Issue
Block a user