From 3a68e2891e988e258e718914a45afd2bad25e6e7 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Perrier Date: Fri, 21 May 2021 18:18:11 +0200 Subject: [PATCH] Add null check. --- Source/Editor/Managed/ManagedEditor.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Source/Editor/Managed/ManagedEditor.cpp b/Source/Editor/Managed/ManagedEditor.cpp index 9ea0f9cfc..93f36f337 100644 --- a/Source/Editor/Managed/ManagedEditor.cpp +++ b/Source/Editor/Managed/ManagedEditor.cpp @@ -232,7 +232,7 @@ void ManagedEditor::Init() args[0] = &isHeadless; args[1] = &skipCompile; Guid sceneId; - if (CommandLine::Options.Game.HasValue() && Guid::Parse(CommandLine::Options.Game.GetValue(), sceneId)) + if (!CommandLine::Options.Game.HasValue() || (CommandLine::Options.Game.HasValue() && Guid::Parse(CommandLine::Options.Game.GetValue(), sceneId))) { sceneId = Guid::Empty; }