Skip to content

Commit

Permalink
Fix #10302 - CalcEquipmentFlowRates assert failure due to out of boun…
Browse files Browse the repository at this point in the history
…ds std::array indexing
  • Loading branch information
jmarrec committed May 27, 2024
1 parent 60147d2 commit 6bc2384
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/EnergyPlus/SolarCollectors.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1979,7 +1979,7 @@ namespace SolarCollectors {
CondOfAir = Conductivity[Index];
PrOfAir = Pr[Index];
DensOfAir = Density[Index];
} else if (Index > NumOfPropDivisions) {
} else if (Index >= NumOfPropDivisions) { // 0-index, hence MaxIndex = NumOfPropDivisions - 1
Index = NumOfPropDivisions - 1;
VisDOfAir = Mu[Index];
CondOfAir = Conductivity[Index];
Expand Down

0 comments on commit 6bc2384

Please sign in to comment.