mirror of
https://github.com/yuzu-emu/yuzu.git
synced 2024-08-25 17:47:17 +02:00
qt: additional fixes for reentrant shutdown
This commit is contained in:
parent
7ef897a277
commit
9ed4c13758
@ -1839,9 +1839,11 @@ void GMainWindow::OnEmulationStopTimeExpired() {
|
||||
|
||||
void GMainWindow::OnEmulationStopped() {
|
||||
shutdown_timer.stop();
|
||||
emu_thread->disconnect();
|
||||
emu_thread->wait();
|
||||
emu_thread = nullptr;
|
||||
if (emu_thread) {
|
||||
emu_thread->disconnect();
|
||||
emu_thread->wait();
|
||||
emu_thread.reset();
|
||||
}
|
||||
|
||||
if (shutdown_dialog) {
|
||||
shutdown_dialog->deleteLater();
|
||||
@ -3029,6 +3031,8 @@ void GMainWindow::OnStopGame() {
|
||||
|
||||
if (OnShutdownBegin()) {
|
||||
OnShutdownBeginDialog();
|
||||
} else {
|
||||
OnEmulationStopped();
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user