mirror of
https://github.com/Z3Prover/z3
synced 2025-05-13 10:44:43 +00:00
fix memory leak in SAT solver exposed by regression tests
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
parent
da63ac809e
commit
aec5a38b14
10 changed files with 82 additions and 30 deletions
|
@ -169,6 +169,7 @@ namespace sat {
|
|||
#endif
|
||||
void * mem = m_allocator.allocate(size);
|
||||
clause * cls = new (mem) clause(m_id_gen.mk(), num_lits, lits, learned);
|
||||
TRACE("sat", tout << "alloc: " << cls->id() << " " << cls << " " << *cls << " " << (learned?"l":"a") << "\n";);
|
||||
SASSERT(!learned || cls->is_learned());
|
||||
return cls;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue