diff options
author | Campbell Barton <ideasman42@gmail.com> | 2021-03-09 15:46:14 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2021-03-09 15:47:43 +0300 |
commit | 2283b6ef6928c2ce0bfe283a9c4744a113412574 (patch) | |
tree | b83cb94314293c08179d57e9a54695c8380ea325 /source/blender/blenkernel/intern/lib_id.c | |
parent | 07a9d39f57093c886fe64b02006cae26193eb8aa (diff) |
Fix the session UUID being set for temporary blend file data
Triggered by temporarily appending library linked data from Python.
Diffstat (limited to 'source/blender/blenkernel/intern/lib_id.c')
-rw-r--r-- | source/blender/blenkernel/intern/lib_id.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/source/blender/blenkernel/intern/lib_id.c b/source/blender/blenkernel/intern/lib_id.c index f3a1c01ad26..af921307bfb 100644 --- a/source/blender/blenkernel/intern/lib_id.c +++ b/source/blender/blenkernel/intern/lib_id.c @@ -171,7 +171,9 @@ static void lib_id_clear_library_data_ex(Main *bmain, ID *id) /* Conceptually, an ID made local is not the same as the linked one anymore. Reflect that by * regenerating its session UUID. */ - BKE_lib_libblock_session_uuid_renew(id); + if ((id->tag & LIB_TAG_TEMP_MAIN) == 0) { + BKE_lib_libblock_session_uuid_renew(id); + } /* We need to tag this IDs and all of its users, conceptually new local ID and original linked * ones are two completely different data-blocks that were virtually remapped, even though in |