diff options
| author | Alex Barney <thealexbarney@gmail.com> | 2021-12-23 09:55:50 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-12-23 13:55:50 -0300 |
| commit | aa932a6df1764b7c600ae0ba4e0c7a0ba802f312 (patch) | |
| tree | 24a390cf2330620aeeab1efbd42ae4099f61ca86 /Ryujinx.HLE/HOS/Applets/Error/ErrorApplet.cs | |
| parent | cb43cc7e322014ce2bd0ee73b06d403be62fa8d5 (diff) | |
Update to LibHac v0.14.3 (#2925)
* Update to LibHac v0.14.3
* Fix loading NCAs that don't have a data partition
Diffstat (limited to 'Ryujinx.HLE/HOS/Applets/Error/ErrorApplet.cs')
| -rw-r--r-- | Ryujinx.HLE/HOS/Applets/Error/ErrorApplet.cs | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/Ryujinx.HLE/HOS/Applets/Error/ErrorApplet.cs b/Ryujinx.HLE/HOS/Applets/Error/ErrorApplet.cs index 1b009de7..c90edda8 100644 --- a/Ryujinx.HLE/HOS/Applets/Error/ErrorApplet.cs +++ b/Ryujinx.HLE/HOS/Applets/Error/ErrorApplet.cs @@ -116,8 +116,10 @@ namespace Ryujinx.HLE.HOS.Applets.Error if (romfs.FileExists(filePath)) { - romfs.OpenFile(out IFile binaryFile, filePath.ToU8Span(), OpenMode.Read).ThrowIfFailure(); - StreamReader reader = new StreamReader(binaryFile.AsStream(), Encoding.Unicode); + using var binaryFile = new UniqueRef<IFile>(); + + romfs.OpenFile(ref binaryFile.Ref(), filePath.ToU8Span(), OpenMode.Read).ThrowIfFailure(); + StreamReader reader = new StreamReader(binaryFile.Get.AsStream(), Encoding.Unicode); return CleanText(reader.ReadToEnd()); } |
