Fix debug command type detection when it's used with argument

This commit is contained in:
Wojtek Figat
2025-05-22 04:45:12 +02:00
parent 66dcfafa2e
commit 32bc73610f

View File

@@ -438,6 +438,8 @@ void DebugCommands::InitAsync()
DebugCommands::CommandFlags DebugCommands::GetCommandFlags(StringView command)
{
CommandFlags result = CommandFlags::None;
if (command.FindLast(' ') != -1)
command = command.Left(command.Find(' '));
// TODO: fix missing string handle on 1st command execution (command gets invalid after InitCommands due to dotnet GC or dotnet interop handles flush)
String commandCopy = command;
command = commandCopy;