mirror of
				https://github.com/PabloMK7/citra.git
				synced 2025-11-03 23:28:48 +00:00 
			
		
		
		
	Remove RomFS::GetFilePointer
This commit is contained in:
		
							parent
							
								
									b62978b5a1
								
							
						
					
					
						commit
						b1f8c2fe67
					
				
					 3 changed files with 5 additions and 20 deletions
				
			
		| 
						 | 
				
			
			@ -143,9 +143,9 @@ bool Module::LoadSharedFont() {
 | 
			
		|||
 | 
			
		||||
    const char16_t* file_name[4] = {u"cbf_std.bcfnt.lz", u"cbf_zh-Hans-CN.bcfnt.lz",
 | 
			
		||||
                                    u"cbf_ko-Hang-KR.bcfnt.lz", u"cbf_zh-Hant-TW.bcfnt.lz"};
 | 
			
		||||
    const u8* font_file =
 | 
			
		||||
        RomFS::GetFilePointer(romfs_buffer.data(), {file_name[font_region_code - 1]});
 | 
			
		||||
    if (font_file == nullptr)
 | 
			
		||||
    const RomFS::RomFSFile font_file =
 | 
			
		||||
        RomFS::GetFile(romfs_buffer.data(), {file_name[font_region_code - 1]});
 | 
			
		||||
    if (font_file.Data() == nullptr)
 | 
			
		||||
        return false;
 | 
			
		||||
 | 
			
		||||
    struct {
 | 
			
		||||
| 
						 | 
				
			
			@ -159,7 +159,7 @@ bool Module::LoadSharedFont() {
 | 
			
		|||
    shared_font_header.status = 2; // successfully loaded
 | 
			
		||||
    shared_font_header.region = font_region_code;
 | 
			
		||||
    shared_font_header.decompressed_size =
 | 
			
		||||
        DecompressLZ11(font_file, shared_font_mem->GetPointer(0x80));
 | 
			
		||||
        DecompressLZ11(font_file.Data(), shared_font_mem->GetPointer(0x80));
 | 
			
		||||
    std::memcpy(shared_font_mem->GetPointer(), &shared_font_header, sizeof(shared_font_header));
 | 
			
		||||
    *shared_font_mem->GetPointer(0x83) = 'U'; // Change the magic from "CFNT" to "CFNU"
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue