VERY experimental Nintendo Switch 2 emulator
C++
CFGU: Use an absolute offset in the config savefile blocks
Subvb3d1c8ba6a57
diff --git a/src/core/hle/service/cfg_u.cpp b/src/core/hle/service/cfg_u.cppindex ee97cf3e5d..33f63a7592 100644--- a/src/core/hle/service/cfg_u.cpp+++ b/src/core/hle/service/cfg_u.cpp@@ -184,7 +184,7 @@ ResultCode GetConfigInfoBlock(u32 block_id, u32 size, u32 flag, u8* output) {if (itr->size <= 4)memcpy(output, &itr->offset_or_data, itr->size);else- memcpy(output, &cfg_config_file_buffer[config->data_entries_offset + itr->offset_or_data], itr->size);+ memcpy(output, &cfg_config_file_buffer[itr->offset_or_data], itr->size);return RESULT_SUCCESS;}@@ -219,6 +219,8 @@ ResultCode CreateConfigInfoBlk(u32 block_id, u32 size, u32 flags, u8 const* databreak;}+ offset += config->data_entries_offset;+config->block_entries[config->total_entries].offset_or_data = offset;// Write the data at the new offset