Crash auto recovery

in the worst way possible
This commit is contained in:
Natsumi
2025-12-23 00:43:04 +13:00
parent 9b20d62a90
commit 3a8627fd0e
6 changed files with 46 additions and 23 deletions

View File

@@ -10,7 +10,6 @@ using System;
using System.Data.SQLite;
using System.Diagnostics.CodeAnalysis;
using System.IO;
using System.Runtime.InteropServices;
using System.Text.Json;
using System.Threading;
#if !LINUX
@@ -128,6 +127,7 @@ namespace VRCX
[SuppressMessage("Interoperability", "CA1416:Validate platform compatibility")]
private static void Main()
{
BrowserSubprocess.Start();
if (Wine.GetIfWine())
{
MessageBox.Show(
@@ -192,20 +192,6 @@ namespace VRCX
#endregion
#region Handle Out Of Memory
catch (SEHException e)
{
logger.Fatal(e, "Unhandled SEH Exception, most likely out of memory, closing.");
var messageBoxResult = MessageBox.Show(
"VRCX has run out of memory and needs to close.\n" +
"We're actively working on fixing this issue. \n" +
e, "Out of Memory", MessageBoxButtons.OK, MessageBoxIcon.Error);
Environment.Exit(0);
}
#endregion
catch (Exception e)
{
var cpuError = WinApi.GetCpuErrorMessage();
@@ -233,7 +219,6 @@ namespace VRCX
StartupArgs.ArgsCheck(args);
SetProgramDirectories();
VRCXStorage.Instance.Load();
BrowserSubprocess.Start();
ConfigureLogger();
GetVersion();
Update.Check();