[Bf-blender-cvs] [fcbbfb77898] master: Fix crash creating new file after modifications

Sergey Sharybin noreply at git.blender.org
Wed Jan 16 11:40:59 CET 2019


Commit: fcbbfb7789890624cdfb78e2b6036414d925616b
Author: Sergey Sharybin
Date:   Wed Jan 16 11:39:30 2019 +0100
Branches: master
https://developer.blender.org/rBfcbbfb7789890624cdfb78e2b6036414d925616b

Fix crash creating new file after modifications

Seems to be caused by cae3750 which changed free() function used
by bmain free to the one which does dependency graph tag. We do
no want to do any tags here.

===================================================================

M	source/blender/blenkernel/intern/main.c

===================================================================

diff --git a/source/blender/blenkernel/intern/main.c b/source/blender/blenkernel/intern/main.c
index 00a950c5302..9f952939eef 100644
--- a/source/blender/blenkernel/intern/main.c
+++ b/source/blender/blenkernel/intern/main.c
@@ -65,7 +65,10 @@ void BKE_main_free(Main *mainvar)
 	int a;
 
 	/* Since we are removing whole main, no need to bother 'properly' (and slowly) removing each ID from it. */
-	const int free_flag = LIB_ID_FREE_NO_MAIN | LIB_ID_FREE_NO_UI_USER | LIB_ID_FREE_NO_USER_REFCOUNT;
+	const int free_flag = (LIB_ID_FREE_NO_MAIN |
+	                       LIB_ID_FREE_NO_UI_USER |
+	                       LIB_ID_FREE_NO_USER_REFCOUNT |
+	                       LIB_ID_FREE_NO_DEG_TAG);
 
 	MEM_SAFE_FREE(mainvar->blen_thumb);



More information about the Bf-blender-cvs mailing list