Skip to content

Commit 21f67ef

Browse files
committed
out of bounds fixes
1 parent 3b3d8ce commit 21f67ef

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/math/lp/dioph_eq.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -926,6 +926,7 @@ namespace lp {
926926
}
927927
find_changed_terms_and_more_changed_rows();
928928
for (unsigned j : m_changed_terms) {
929+
if (j >= m_l_matrix.column_count()) continue;
929930
for (const auto & cs: m_l_matrix.column(j)) {
930931
m_changed_rows.insert(cs.var());
931932
}
@@ -1328,6 +1329,7 @@ namespace lp {
13281329
lia_move ret = lia_move::undef;
13291330
for (unsigned j : m_changed_terms) {
13301331
cleanup.push_back(j);
1332+
if (j >= lra.column_count()) continue;
13311333
if (!lra.column_has_term(j) || lra.column_is_free(j) ||
13321334
is_fixed(j) || !lia.column_is_int(j)) {
13331335
continue;

0 commit comments

Comments
 (0)