From 1f92cbc059aaca13823c71a9279393661b050d34 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Tue, 25 Sep 2018 18:14:29 -0400 Subject: fsmitm_romfsbuild: Remove unnecessary loops in Build() The std::vector instances are already initially allocated with all entries having these values, there's no need to loop through and fill them with it again when they aren't modified. --- src/core/file_sys/fsmitm_romfsbuild.cpp | 6 ------ 1 file changed, 6 deletions(-) (limited to 'src/core/file_sys') diff --git a/src/core/file_sys/fsmitm_romfsbuild.cpp b/src/core/file_sys/fsmitm_romfsbuild.cpp index a8af5e14f..b8807e5ca 100644 --- a/src/core/file_sys/fsmitm_romfsbuild.cpp +++ b/src/core/file_sys/fsmitm_romfsbuild.cpp @@ -233,12 +233,6 @@ std::map RomFSBuildContext::Build() { std::vector dir_table(dir_table_size); std::vector file_table(file_table_size); - // Clear out hash tables. - for (u32 i = 0; i < dir_hash_table_entry_count; i++) - dir_hash_table[i] = ROMFS_ENTRY_EMPTY; - for (u32 i = 0; i < file_hash_table_entry_count; i++) - file_hash_table[i] = ROMFS_ENTRY_EMPTY; - std::shared_ptr cur_file; // Determine file offsets. -- cgit v1.2.3