Fix #107946: Blender crashes when relocating a library to another library that uses the same "2nd-level" library.
The issue here is that the `parent` pointer of indirectly linked libraries would not be propoerly cleared when their current parent was deleted. Note that this fix will leave effectively indirectly linked libraries shown as directly used ones in the UI, until the blendfile is saved and reloaded. This is not a new issue though, deleting a parent library in the Outliner has the same effect.
This commit is contained in:
@@ -1894,7 +1894,7 @@ void BKE_blendfile_library_relocate(BlendfileLinkAppendContext *lapp_context,
|
||||
if (lib->id.tag & LIB_TAG_DOIT) {
|
||||
id_us_clear_real(&lib->id);
|
||||
if (lib->id.us == 0) {
|
||||
BKE_id_free(bmain, (ID *)lib);
|
||||
BKE_id_delete(bmain, lib);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user