diff options
author | Bastien Montagne <b.mont29@gmail.com> | 2020-03-12 20:05:20 +0300 |
---|---|---|
committer | Bastien Montagne <b.mont29@gmail.com> | 2020-03-12 20:08:11 +0300 |
commit | 11e48277386c1811507878e3ffe7f7e10e26ac20 (patch) | |
tree | ff9c97057f8203d9845498a94ce0cd164a933b92 /source/blender/blenkernel | |
parent | 4669dfe2cc2441e55bbd432c690047c4828d1c39 (diff) |
Fix T74670: crash during copy paste of objects.
Embedded data should always be considered as outside of Main database
here.
Note that it's a bit of an edge case to decide whether those should
always have their `LIB_TAG_NOMAIN` set too, or not? For now, let's keep
things as they are here.
Diffstat (limited to 'source/blender/blenkernel')
-rw-r--r-- | source/blender/blenkernel/intern/lib_id.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/blenkernel/intern/lib_id.c b/source/blender/blenkernel/intern/lib_id.c index c342185d0b8..27d4b8dd047 100644 --- a/source/blender/blenkernel/intern/lib_id.c +++ b/source/blender/blenkernel/intern/lib_id.c @@ -162,7 +162,8 @@ static void lib_id_clear_library_data_ex(Main *bmain, ID *id) { bNodeTree *ntree = NULL; Key *key = NULL; - const bool id_in_mainlist = (id->tag & LIB_TAG_NO_MAIN) == 0; + const bool id_in_mainlist = (id->tag & LIB_TAG_NO_MAIN) == 0 && + (id->flag & LIB_EMBEDDED_DATA) == 0; lib_id_library_local_paths(bmain, id->lib, id); |