Fix (unreported) Broken BLI_threadapi_exit()
.
Function would not clear the static scheduler pointer, which lead to crash (mem use after free) when trying to re-init and use the task API again. Should not happen in Blender itself, but could in other cases (like some future gtests ;) ).
This commit is contained in:
parent
b640265f77
commit
30d9366d17
@ -161,6 +161,7 @@ void BLI_threadapi_exit(void)
|
||||
{
|
||||
if (task_scheduler) {
|
||||
BLI_task_scheduler_free(task_scheduler);
|
||||
task_scheduler = NULL;
|
||||
}
|
||||
BLI_spin_end(&_malloc_lock);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user