diff options
author | bunnei <bunneidev@gmail.com> | 2020-09-22 13:42:47 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-09-22 13:42:47 -0700 |
commit | c07fd2898b45032b5e4084fc49a19018ad099ba6 (patch) | |
tree | 9f906d43d51ec8421e7294b31380fddbb8ddc060 | |
parent | 53829d4cbd6cc84963191a483688d407ec6fe14d (diff) | |
parent | a881efbf261f901ceac20286e46c6251c473bc17 (diff) |
Merge pull request #4697 from lioncash/copy5
ips_layer: Eliminate a redundant copy in Parse()
-rw-r--r-- | src/core/file_sys/ips_layer.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/core/file_sys/ips_layer.cpp b/src/core/file_sys/ips_layer.cpp index a08a70efd..dd779310f 100644 --- a/src/core/file_sys/ips_layer.cpp +++ b/src/core/file_sys/ips_layer.cpp @@ -245,9 +245,11 @@ void IPSwitchCompiler::Parse() { // Read rest of patch while (true) { - if (i + 1 >= lines.size()) + if (i + 1 >= lines.size()) { break; - const auto patch_line = lines[++i]; + } + + const auto& patch_line = lines[++i]; // Start of new patch if (StartsWith(patch_line, "@enabled") || StartsWith(patch_line, "@disabled")) { |