-1 list allocation per frame yay

This commit is contained in:
Morilli 2024-03-26 19:20:54 +01:00
parent d498f8c3be
commit 032d1b85d6
1 changed files with 2 additions and 2 deletions

View File

@ -2396,12 +2396,12 @@ namespace BizHawk.Client.EmuHawk
PathsFromDragDrop = null; PathsFromDragDrop = null;
}); });
List<string[]> todo = new(); string[][] todo = Array.Empty<string[]>();
lock (_singleInstanceForwardedArgs) lock (_singleInstanceForwardedArgs)
{ {
if (_singleInstanceForwardedArgs.Count > 0) if (_singleInstanceForwardedArgs.Count > 0)
{ {
todo = new List<string[]>(_singleInstanceForwardedArgs); todo = _singleInstanceForwardedArgs.ToArray();
_singleInstanceForwardedArgs.Clear(); _singleInstanceForwardedArgs.Clear();
} }
} }