Blendloader: Option to reports to skip list of recursively liboverride-resynced libs.

This extra info is not always needed/convinient to use, and requires
special attention to free the list, so allow not generating it.
This commit is contained in:
Bastien Montagne 2021-08-13 16:26:58 +02:00
parent 7772880d69
commit bb0e29c922
2 changed files with 2 additions and 1 deletions

View File

@ -1631,7 +1631,7 @@ static void lib_override_library_main_resync_on_library_indirect_level(
CLOG_INFO(&LOG, 2, "\tSuccess: %d", success);
if (success) {
reports->count.resynced_lib_overrides++;
if (library_indirect_level > 0 &&
if (library_indirect_level > 0 && reports->do_resynced_lib_overrides_libraries_list &&
BLI_linklist_index(reports->resynced_lib_overrides_libraries, library) < 0) {
BLI_linklist_prepend(&reports->resynced_lib_overrides_libraries, library);
reports->resynced_lib_overrides_libraries_count++;

View File

@ -118,6 +118,7 @@ typedef struct BlendFileReadReport {
/* Number of libraries which had overrides that needed to be resynced, and a single linked list
* of those. */
int resynced_lib_overrides_libraries_count;
bool do_resynced_lib_overrides_libraries_list;
struct LinkNode *resynced_lib_overrides_libraries;
} BlendFileReadReport;