1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

sync: protect against sporadic failing tests in macos

This commit is contained in:
Delyan Angelov 2020-03-08 16:40:50 +02:00 committed by GitHub
parent ee6f2f84bb
commit 8df265a581
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -135,6 +135,9 @@ fn process_in_thread(pool mut PoolProcessor, task_id int) {
idx = pool.ntask idx = pool.ntask
pool.ntask++ pool.ntask++
pool.ntask_mtx.unlock() pool.ntask_mtx.unlock()
if idx >= ilen {
break
}
pool.results[idx] = cb(pool, idx, task_id) pool.results[idx] = cb(pool, idx, task_id)
} }
pool.waitgroup.done() pool.waitgroup.done()