Skip to content

Commit

Permalink
prevent crash when opening calc debug on junk files
Browse files Browse the repository at this point in the history
  • Loading branch information
poco0317 committed Jul 21, 2022
1 parent d0c1864 commit fe4aae0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/Etterna/Models/StepsAndStyles/Steps.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1071,7 +1071,9 @@ class LunaSteps : public Luna<Steps>
auto vals = SONGMAN->calc->jack_diff.at(hand);
auto stam_vals = SONGMAN->calc->jack_stam_stuff.at(hand);
auto loss_vals = SONGMAN->calc->jack_loss.at(hand);
for (size_t i = 0; i < vals.size(); i++) {
for (size_t i = 0; i < vals.size() && i < stam_vals.size() &&
i < loss_vals.size();
i++) {
auto v1 = vals[i].first;
auto v2 = vals[i].second;
auto v3 = 0.F;
Expand Down

0 comments on commit fe4aae0

Please sign in to comment.