Fix (studio-reported) issue with overrides on library relocating.

Liboverrides that were using a missing linked reference ID would not get
their 'MISSING' tag properly cleared afer relocating, in case their
linked reference is no more missing.

Reported by Andy (@eyecandy) from Blender studio.
This commit is contained in:
Bastien Montagne 2022-10-20 11:22:51 +02:00
parent ff157d7eba
commit bd9d68e4dc
Notes: blender-bot 2023-02-14 03:44:41 +01:00
Referenced by issue #100749, Blender LTS: Maintenance Task 3.3
1 changed files with 3 additions and 0 deletions

View File

@ -1614,6 +1614,9 @@ void BKE_blendfile_library_relocate(BlendfileLinkAppendContext *lapp_context,
(id->tag & LIB_TAG_PRE_EXISTING) == 0) {
continue;
}
if ((id->override_library->reference->tag & LIB_TAG_MISSING) == 0) {
id->tag &= ~LIB_TAG_MISSING;
}
if ((id->override_library->reference->tag & LIB_TAG_PRE_EXISTING) == 0) {
BKE_lib_override_library_update(bmain, id);
}