Skip to content

Commit

Permalink
Try to fix crash for
Browse files Browse the repository at this point in the history
ModelicaTest.Tables.CombiTable2D[sv].Test2[167]
when compiled with VS 2019.
  • Loading branch information
HansOlsson authored and beutlich committed Mar 5, 2023
1 parent f2af3b3 commit 7dc882f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Modelica/Resources/C-Sources/ModelicaStandardTables.c
Original file line number Diff line number Diff line change
Expand Up @@ -6943,7 +6943,7 @@ static CubicHermite2D* spline2DInit(_In_ const double* table, size_t nRow,
return NULL;
}
/* Copy coefficients */
for (j = 0; j < nCol - 1; j++) {
for (j = 0; j < nCol - 2; j++) {
const double* c1 = spline1D[j];
double* c2 = spline[j];
c2[0] = c1[0];
Expand All @@ -6968,7 +6968,7 @@ static CubicHermite2D* spline2DInit(_In_ const double* table, size_t nRow,
return NULL;
}
/* Copy coefficients */
for (i = 0; i < nRow - 1; i++) {
for (i = 0; i < nRow - 2; i++) {
const double* c1 = spline1D[i];
double* c2 = spline[i];
c2[0] = c1[0];
Expand Down

0 comments on commit 7dc882f

Please sign in to comment.