3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-04-24 01:25:31 +00:00
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
Nikolaj Bjorner 2019-06-03 20:35:13 -07:00 committed by Nuno Lopes
parent 59330b3855
commit 1f84381c4c
2 changed files with 24 additions and 5 deletions

View file

@ -1243,6 +1243,8 @@ namespace sat {
unsigned error_code = 0;
lbool result = l_undef;
bool canceled = false;
std::mutex mux;
auto worker_thread = [&](int i) {
try {
lbool r = l_undef;
@ -1259,8 +1261,8 @@ namespace sat {
r = check(num_lits, lits);
}
bool first = false;
#pragma omp critical (par_solver)
{
std::lock_guard<std::mutex> lock(mux);
if (finished_id == -1) {
finished_id = i;
first = true;