1
0
mirror of https://git.suyu.dev/suyu/suyu synced 2025-01-29 02:57:00 -06:00

file_util: std::move FST entries in ScanDirectoryTree()

Avoids unnecessary copies when building up the FST entries.
This commit is contained in:
Lioncash 2018-07-21 22:31:41 -04:00
parent 53a219f163
commit 964154ce44

View File

@ -480,7 +480,7 @@ unsigned ScanDirectoryTree(const std::string& directory, FSTEntry& parent_entry,
(*num_entries_out)++;
// Push into the tree
parent_entry.children.push_back(entry);
parent_entry.children.push_back(std::move(entry));
return true;
};