mirror of
				https://github.com/PabloMK7/citra.git
				synced 2025-11-03 23:28:48 +00:00 
			
		
		
		
	fs_user: std::move vectors where applicable
Allows removing some allocation churn in some locations by moving std::vectors into Path where applicable.
This commit is contained in:
		
							parent
							
								
									36809b2e2e
								
							
						
					
					
						commit
						ba2ae9616a
					
				
					 8 changed files with 73 additions and 72 deletions
				
			
		| 
						 | 
				
			
			@ -149,8 +149,8 @@ bool Module::LoadSharedFont() {
 | 
			
		|||
    const u64_le shared_font_archive_id_low = 0x0004009b00014002 | ((font_region_code - 1) << 8);
 | 
			
		||||
 | 
			
		||||
    FileSys::NCCHArchive archive(shared_font_archive_id_low, Service::FS::MediaType::NAND);
 | 
			
		||||
    std::vector<u8> romfs_path(20, 0); // 20-byte all zero path for opening RomFS
 | 
			
		||||
    FileSys::Path file_path(romfs_path);
 | 
			
		||||
    // 20-byte all zero path for opening RomFS
 | 
			
		||||
    const FileSys::Path file_path(std::vector<u8>(20, 0));
 | 
			
		||||
    FileSys::Mode open_mode = {};
 | 
			
		||||
    open_mode.read_flag.Assign(1);
 | 
			
		||||
    auto file_result = archive.OpenFile(file_path, open_mode);
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue