Fix LibOverride crashing in some cases where reference linked data gets MIA.
When the root of an override hierarchy disapears, there is no way to do a proper resync, just abort. Reported by studio, thx.
This commit is contained in:
parent
4a02b9ffeb
commit
f4abd3cfc4
|
@ -1013,6 +1013,15 @@ bool BKE_lib_override_library_resync(Main *bmain,
|
|||
|
||||
ID *id_root_reference = id_root->override_library->reference;
|
||||
|
||||
if (id_root_reference->tag & LIB_TAG_MISSING) {
|
||||
BKE_reportf(reports != NULL ? reports->reports : NULL,
|
||||
RPT_ERROR,
|
||||
"impossible to resync data-block %s and its dependencies, as its linked reference "
|
||||
"is missing",
|
||||
id_root->name + 2);
|
||||
return false;
|
||||
}
|
||||
|
||||
BKE_main_relations_create(bmain, 0);
|
||||
LibOverrideGroupTagData data = {.bmain = bmain,
|
||||
.scene = scene,
|
||||
|
|
Loading…
Reference in New Issue