svn merge ^/trunk/blender -r40395:40405
[blender.git] / source / blender / windowmanager / intern / wm_init_exit.c
index cf3f12da7674944641e9dd7508a3433d9989c89f..19ad4a1b0ed025879af94d0bc8eb07ec1f86c1c9 100644 (file)
@@ -64,6 +64,7 @@
 #include "BKE_material.h" /* clear_matcopybuf */
 
 #include "BLI_blenlib.h"
+#include "BLI_cellalloc.h"
 #include "BLI_winstuff.h"
 
 #include "RE_pipeline.h"               /* RE_ free stuff */
@@ -457,8 +458,10 @@ void WM_exit_ext(bContext *C, const short do_python)
        GHOST_DisposeSystemPaths();
 
        if(MEM_get_memory_blocks_in_use()!=0) {
-               printf("Error: Not freed memory blocks: %d\n", MEM_get_memory_blocks_in_use());
+               printf("Error: Not freed memory blocks: %d\n", MEM_get_memory_blocks_in_use()+BLI_cellalloc_get_totblock());
                MEM_printmemlist();
+               BLI_cellalloc_printleaks();
+               BLI_cellalloc_destroy();
        }
        wm_autosave_delete();