diff options
| author | Alex Barney <thealexbarney@gmail.com> | 2019-06-06 17:01:44 -0500 |
|---|---|---|
| committer | Ac_K <Acoustik666@gmail.com> | 2019-06-07 00:01:44 +0200 |
| commit | 3541a9053f7728772e3face4221d2a23a67bfed9 (patch) | |
| tree | 3feb0d7228918a23b2efdcb4d30fa803214129d7 /Ryujinx.HLE/HOS/Services/FspSrv/IFileSystem.cs | |
| parent | 6fbe87cccc7069a39140f19464ead95b6bd12c72 (diff) | |
Update to LibHac 0.4.1 (#698)
* Update to LibHac 0.4.1
Updates the IFile Read and Write methods to use any specified ReadOption and WriteOption
* Move casts around
Diffstat (limited to 'Ryujinx.HLE/HOS/Services/FspSrv/IFileSystem.cs')
| -rw-r--r-- | Ryujinx.HLE/HOS/Services/FspSrv/IFileSystem.cs | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/Ryujinx.HLE/HOS/Services/FspSrv/IFileSystem.cs b/Ryujinx.HLE/HOS/Services/FspSrv/IFileSystem.cs index 9e772213..74ba6216 100644 --- a/Ryujinx.HLE/HOS/Services/FspSrv/IFileSystem.cs +++ b/Ryujinx.HLE/HOS/Services/FspSrv/IFileSystem.cs @@ -50,7 +50,7 @@ namespace Ryujinx.HLE.HOS.Services.FspSrv { string name = ReadUtf8String(context); - int createOption = context.RequestData.ReadInt32(); + CreateFileOptions createOption = (CreateFileOptions)context.RequestData.ReadInt32(); context.RequestData.BaseStream.Position += 4; long size = context.RequestData.ReadInt64(); @@ -72,7 +72,7 @@ namespace Ryujinx.HLE.HOS.Services.FspSrv try { - _provider.CreateFile(name, size, (CreateFileOptions)createOption); + _provider.CreateFile(name, size, createOption); } catch (DirectoryNotFoundException) { @@ -323,7 +323,7 @@ namespace Ryujinx.HLE.HOS.Services.FspSrv // OpenFile(u32 mode, buffer<bytes<0x301>, 0x19, 0x301> path) -> object<nn::fssrv::sf::IFile> file public long OpenFile(ServiceCtx context) { - int mode = context.RequestData.ReadInt32(); + OpenMode mode = (OpenMode)context.RequestData.ReadInt32(); string name = ReadUtf8String(context); @@ -341,7 +341,7 @@ namespace Ryujinx.HLE.HOS.Services.FspSrv try { - LibHac.Fs.IFile file = _provider.OpenFile(name, (OpenMode)mode); + LibHac.Fs.IFile file = _provider.OpenFile(name, mode); fileInterface = new IFile(file, name); } @@ -367,7 +367,7 @@ namespace Ryujinx.HLE.HOS.Services.FspSrv // OpenDirectory(u32 filter_flags, buffer<bytes<0x301>, 0x19, 0x301> path) -> object<nn::fssrv::sf::IDirectory> directory public long OpenDirectory(ServiceCtx context) { - int mode = context.RequestData.ReadInt32(); + OpenDirectoryMode mode = (OpenDirectoryMode)context.RequestData.ReadInt32(); string name = ReadUtf8String(context); @@ -385,7 +385,7 @@ namespace Ryujinx.HLE.HOS.Services.FspSrv try { - LibHac.Fs.IDirectory dir = _provider.OpenDirectory(name, (OpenDirectoryMode) mode); + LibHac.Fs.IDirectory dir = _provider.OpenDirectory(name, mode); dirInterface = new IDirectory(dir); } |
