Also protect against mutation of `IEnumerable` for `onconsoleclose`
see7a26546cf
, fixesdc66b4357
This commit is contained in:
parent
7a26546cfc
commit
9815b377d1
|
@ -266,7 +266,8 @@ namespace BizHawk.Client.EmuHawk
|
||||||
public void Close()
|
public void Close()
|
||||||
{
|
{
|
||||||
foreach (var closeCallback in RegisteredFunctions
|
foreach (var closeCallback in RegisteredFunctions
|
||||||
.Where(l => l.Event == "OnConsoleClose"))
|
.Where(static l => l.Event == "OnConsoleClose")
|
||||||
|
.ToList())
|
||||||
{
|
{
|
||||||
closeCallback.Call();
|
closeCallback.Call();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue