3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-08-04 18:30:24 +00:00

Fix memory leak in lar_solver by adding var_register cleanup

Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot] 2025-06-20 23:16:05 +00:00
parent 6eeed84383
commit 3a1a8a9f14

View file

@ -231,6 +231,7 @@ namespace lp {
lar_solver::~lar_solver() { lar_solver::~lar_solver() {
for (auto t : m_imp->m_terms) for (auto t : m_imp->m_terms)
delete t; delete t;
m_imp->m_var_register.clear();
} }
void lar_solver::clear_columns_with_changed_bounds() { m_imp->m_columns_with_changed_bounds.reset(); } void lar_solver::clear_columns_with_changed_bounds() { m_imp->m_columns_with_changed_bounds.reset(); }