mirror of
https://git.citron-emu.org/citron/emulator
synced 2025-12-24 04:33:44 +00:00
fix: implement DeleteCacheStorage stub to prevent TOTK crashes
- Add stubbed DeleteCacheStorage function to FSP_SRV service - Return success instead of causing assertion failure - Prevents userspace PANIC when games attempt to delete cache storage Signed-off-by: Zephyron <zephyron@citron-emu.org>
This commit is contained in:
@@ -77,7 +77,7 @@ FSP_SRV::FSP_SRV(Core::System& system_)
|
||||
{30, D<&FSP_SRV::OpenGameCardStorage>, "OpenGameCardStorage"},
|
||||
{31, D<&FSP_SRV::OpenGameCardFileSystem>, "OpenGameCardFileSystem"},
|
||||
{32, D<&FSP_SRV::ExtendSaveDataFileSystem>, "ExtendSaveDataFileSystem"},
|
||||
{33, nullptr, "DeleteCacheStorage"},
|
||||
{33, D<&FSP_SRV::DeleteCacheStorage>, "DeleteCacheStorage"},
|
||||
{34, D<&FSP_SRV::GetCacheStorageSize>, "GetCacheStorageSize"},
|
||||
{35, nullptr, "CreateSaveDataFileSystemByHashSalt"},
|
||||
{36, nullptr, "OpenHostFileSystemWithOption"},
|
||||
@@ -606,6 +606,12 @@ Result FSP_SRV::ExtendSaveDataFileSystem(FileSys::SaveDataSpaceId space_id, u64
|
||||
R_SUCCEED();
|
||||
}
|
||||
|
||||
Result FSP_SRV::DeleteCacheStorage(u16 index) {
|
||||
LOG_WARNING(Service_FS, "(STUBBED) called, index={}", index);
|
||||
// Cache storage deletion is not implemented, but we return success to prevent crashes
|
||||
R_SUCCEED();
|
||||
}
|
||||
|
||||
Result FSP_SRV::GetCacheStorageSize(s32 index, Out<s64> out_data_size, Out<s64> out_journal_size) {
|
||||
LOG_WARNING(Service_FS, "(STUBBED) called with index={}", index);
|
||||
|
||||
|
||||
@@ -110,6 +110,7 @@ private:
|
||||
Result OpenMultiCommitManager(OutInterface<IMultiCommitManager> out_interface);
|
||||
Result ExtendSaveDataFileSystem(FileSys::SaveDataSpaceId space_id, u64 save_data_id,
|
||||
s64 available_size, s64 journal_size);
|
||||
Result DeleteCacheStorage(u16 index);
|
||||
Result GetCacheStorageSize(s32 index, Out<s64> out_data_size, Out<s64> out_journal_size);
|
||||
Result OpenDeviceOperator(OutInterface<IDeviceOperator> out_interface);
|
||||
Result OpenSdCardDetectionEventNotifier(OutInterface<IEventNotifier> out_interface);
|
||||
|
||||
Reference in New Issue
Block a user