aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorgdkchan <gab.dark.100@gmail.com>2019-02-15 12:44:25 -0300
committerThomas Guillemard <thog@protonmail.com>2019-02-15 16:44:25 +0100
commitb5fcf883e863c5f449855dc1113db07383b914b5 (patch)
tree3824854cb19f337050b464b76cd0dfd32969f00a
parentfec8e3489d5719d0621b34ddfb9992506d7cf0f1 (diff)
Implement IStorage GetSize (#585)
-rw-r--r--Ryujinx.HLE/HOS/Services/FspSrv/IStorage.cs11
1 files changed, 10 insertions, 1 deletions
diff --git a/Ryujinx.HLE/HOS/Services/FspSrv/IStorage.cs b/Ryujinx.HLE/HOS/Services/FspSrv/IStorage.cs
index d000635d..85ab2cf6 100644
--- a/Ryujinx.HLE/HOS/Services/FspSrv/IStorage.cs
+++ b/Ryujinx.HLE/HOS/Services/FspSrv/IStorage.cs
@@ -16,7 +16,8 @@ namespace Ryujinx.HLE.HOS.Services.FspSrv
{
_commands = new Dictionary<int, ServiceProcessRequest>
{
- { 0, Read }
+ { 0, Read },
+ { 4, GetSize }
};
_baseStream = baseStream;
@@ -51,5 +52,13 @@ namespace Ryujinx.HLE.HOS.Services.FspSrv
return 0;
}
+
+ // GetSize() -> u64 size
+ public long GetSize(ServiceCtx context)
+ {
+ context.ResponseData.Write(_baseStream.Length);
+
+ return 0;
+ }
}
}