Use one global task scheduler for all the tasks
[blender.git] / source / blender / windowmanager / intern / wm_init_exit.c
index 63cf1eeb40d9d3b0ee6813414169407245e3a2fd..2663b3e8c7645837d36b3aa4fa99073f05edda39 100644 (file)
@@ -51,6 +51,7 @@
 #include "BLI_listbase.h"
 #include "BLI_path_util.h"
 #include "BLI_string.h"
+#include "BLI_threads.h"
 #include "BLI_utildefines.h"
 
 #include "BKE_blender.h"
@@ -510,12 +511,14 @@ void WM_exit_ext(bContext *C, const short do_python)
        
        GHOST_DisposeSystemPaths();
 
+       BLI_threadapi_exit();
+
        if (MEM_get_memory_blocks_in_use() != 0) {
                printf("Error: Not freed memory blocks: %d\n", MEM_get_memory_blocks_in_use());
                MEM_printmemlist();
        }
        wm_autosave_delete();
-       
+
        printf("\nBlender quit\n");
        
 #ifdef WIN32