From aa932a6df1764b7c600ae0ba4e0c7a0ba802f312 Mon Sep 17 00:00:00 2001 From: Alex Barney Date: Thu, 23 Dec 2021 09:55:50 -0700 Subject: Update to LibHac v0.14.3 (#2925) * Update to LibHac v0.14.3 * Fix loading NCAs that don't have a data partition --- Ryujinx.HLE/HOS/Services/Sdb/Pl/SharedFontManager.cs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'Ryujinx.HLE/HOS/Services/Sdb') diff --git a/Ryujinx.HLE/HOS/Services/Sdb/Pl/SharedFontManager.cs b/Ryujinx.HLE/HOS/Services/Sdb/Pl/SharedFontManager.cs index 13bb9ff5..094ad607 100644 --- a/Ryujinx.HLE/HOS/Services/Sdb/Pl/SharedFontManager.cs +++ b/Ryujinx.HLE/HOS/Services/Sdb/Pl/SharedFontManager.cs @@ -74,9 +74,11 @@ namespace Ryujinx.HLE.HOS.Services.Sdb.Pl Nca nca = new Nca(_device.System.KeySet, ncaFileStream); IFileSystem romfs = nca.OpenFileSystem(NcaSectionType.Data, _device.System.FsIntegrityCheckLevel); - romfs.OpenFile(out IFile fontFile, ("/" + fontFilename).ToU8Span(), OpenMode.Read).ThrowIfFailure(); + using var fontFile = new UniqueRef(); - data = DecryptFont(fontFile.AsStream()); + romfs.OpenFile(ref fontFile.Ref(), ("/" + fontFilename).ToU8Span(), OpenMode.Read).ThrowIfFailure(); + + data = DecryptFont(fontFile.Get.AsStream()); } FontInfo info = new FontInfo((int)fontOffset, data.Length); -- cgit v1.2.3