[Bf-blender-cvs] [d7e7e9af026] master: Add WorkSpace to list of ID types that are not supported by standard copy mechanism for now.

Bastien Montagne noreply at git.blender.org
Mon Mar 11 20:45:58 CET 2019


Commit: d7e7e9af026e5713de5299fed9b5de463a51f3bc
Author: Bastien Montagne
Date:   Mon Mar 11 20:43:25 2019 +0100
Branches: master
https://developer.blender.org/rBd7e7e9af026e5713de5299fed9b5de463a51f3bc

Add WorkSpace to list of ID types that are not supported by standard copy mechanism for now.

Am not sure whether we want to support that at some point, but at least
if we don’t, make it safe and get out of copy code early, previously
trying to duplicate workspace through BKE_id_copy() would have given a
very bad a broken result...

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

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

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

diff --git a/source/blender/blenkernel/intern/library.c b/source/blender/blenkernel/intern/library.c
index 52796d06a3f..a66030a11b4 100644
--- a/source/blender/blenkernel/intern/library.c
+++ b/source/blender/blenkernel/intern/library.c
@@ -515,7 +515,7 @@ static int id_copy_libmanagement_cb(void *user_data, ID *UNUSED(id_self), ID **i
 
 bool BKE_id_copy_is_allowed(const ID *id)
 {
-#define LIB_ID_TYPES_NOCOPY ID_LI, ID_SCR, ID_WM,  /* Not supported */ \
+#define LIB_ID_TYPES_NOCOPY ID_LI, ID_SCR, ID_WM, ID_WS,  /* Not supported */ \
                             ID_IP  /* Deprecated */
 
 	return !ELEM(GS(id->name), LIB_ID_TYPES_NOCOPY);



More information about the Bf-blender-cvs mailing list