From e00ca92063b9dda7b3272f6461610743cfa83ad5 Mon Sep 17 00:00:00 2001 From: riperiperi Date: Wed, 23 Sep 2020 22:57:18 +0100 Subject: Return "NotAvailable" when no UserChannel data is present. (#1569) * Return "NotAvailable" when no UserChannel data is present. * Return ObjectInvalid for undefined parameter kinds. * No need to specify which, there's only one. * Just works as a literal string. --- Ryujinx.HLE/HOS/UserChannelPersistence.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'Ryujinx.HLE/HOS/UserChannelPersistence.cs') diff --git a/Ryujinx.HLE/HOS/UserChannelPersistence.cs b/Ryujinx.HLE/HOS/UserChannelPersistence.cs index 62f28fee..13e7364f 100644 --- a/Ryujinx.HLE/HOS/UserChannelPersistence.cs +++ b/Ryujinx.HLE/HOS/UserChannelPersistence.cs @@ -31,7 +31,9 @@ namespace Ryujinx.HLE.HOS public byte[] Pop() { - return _userChannelStorages.Pop(); + _userChannelStorages.TryPop(out byte[] result); + + return result; } public bool IsEmpty => _userChannelStorages.Count == 0; -- cgit v1.2.3