add BT_SetTerminate to all threads
This commit is contained in:
@@ -706,6 +706,7 @@ void parallel_for(size_t nb_elements, std::function<void(size_t i)> functor, boo
|
||||
{
|
||||
size_t start = i * batch_size;
|
||||
my_threads[i] = std::thread([functor, start, batch_size]() {
|
||||
BT_SetTerminate();
|
||||
for (size_t j = start; j < start + batch_size; j++)
|
||||
functor(j);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user