From ccf96bf5e673456ec80f72725e4c9afa4e4c5a85 Mon Sep 17 00:00:00 2001 From: TSRBerry <20988865+TSRBerry@users.noreply.github.com> Date: Tue, 17 Sep 2024 20:42:00 +0200 Subject: [PATCH] Wait for async task to complete (#7122) This way exceptions thrown during the execution of CheckLaunchState() will correctly invoke the unhandled exception handler and cause Ryujinx to crash. --- src/Ryujinx/UI/Windows/MainWindow.axaml.cs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/Ryujinx/UI/Windows/MainWindow.axaml.cs b/src/Ryujinx/UI/Windows/MainWindow.axaml.cs index 348412e78c..1f57ada388 100644 --- a/src/Ryujinx/UI/Windows/MainWindow.axaml.cs +++ b/src/Ryujinx/UI/Windows/MainWindow.axaml.cs @@ -482,9 +482,7 @@ namespace Ryujinx.Ava.UI.Windows LoadApplications(); } -#pragma warning disable CS4014 // Because this call is not awaited, execution of the current method continues before the call is completed - CheckLaunchState(); -#pragma warning restore CS4014 // Because this call is not awaited, execution of the current method continues before the call is completed + CheckLaunchState().Wait(); } private void SetMainContent(Control content = null)