diff options
author | Bastien Montagne <bastien@blender.org> | 2021-06-23 10:51:11 +0300 |
---|---|---|
committer | Bastien Montagne <bastien@blender.org> | 2021-06-23 11:37:00 +0300 |
commit | 82c17082ba0e53d782ac6be703d71d188a331dde (patch) | |
tree | 3bdb6f1a86bc8bf506d28046ada40b7f881dba86 /source/blender/blenloader/BLO_read_write.h | |
parent | 071799d4fc44f422abacbdad09bb45fb95de89f2 (diff) |
Revert "Revert "Enhanced stats/reports for blendfile reading.""
This reverts commit rB3a48147b8ab92, and fixes the issues with linking
etc.
Change compared to previous buggy commit (rBf8d219dfd4c31) is that
new `BlendFileReadReports` reports are now passed to the lowest level
function generating the `FileData` (`filedata_new()`), which ensures
(and asserts) that all code using it does have a valid non-NULL pointer
to a `BlendFileReadReport` data.
Sorry for the noise, it's always when you think a change is trivial and
do not test it well enough that you end up doing those kind of
mistakes...
Diffstat (limited to 'source/blender/blenloader/BLO_read_write.h')
-rw-r--r-- | source/blender/blenloader/BLO_read_write.h | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/source/blender/blenloader/BLO_read_write.h b/source/blender/blenloader/BLO_read_write.h index ea0532d884b..86c7c367816 100644 --- a/source/blender/blenloader/BLO_read_write.h +++ b/source/blender/blenloader/BLO_read_write.h @@ -54,6 +54,7 @@ typedef struct BlendExpander BlendExpander; typedef struct BlendLibReader BlendLibReader; typedef struct BlendWriter BlendWriter; +struct BlendFileReadReport; struct Main; struct ReportList; @@ -216,7 +217,7 @@ bool BLO_read_requires_endian_switch(BlendDataReader *reader); bool BLO_read_data_is_undo(BlendDataReader *reader); void BLO_read_data_globmap_add(BlendDataReader *reader, void *oldaddr, void *newaddr); void BLO_read_glob_list(BlendDataReader *reader, struct ListBase *list); -struct ReportList *BLO_read_data_reports(BlendDataReader *reader); +struct BlendFileReadReport *BLO_read_data_reports(BlendDataReader *reader); /* Blend Read Lib API * =================== @@ -233,7 +234,7 @@ ID *BLO_read_get_new_id_address(BlendLibReader *reader, struct Library *lib, str /* Misc. */ bool BLO_read_lib_is_undo(BlendLibReader *reader); struct Main *BLO_read_lib_get_main(BlendLibReader *reader); -struct ReportList *BLO_read_lib_reports(BlendLibReader *reader); +struct BlendFileReadReport *BLO_read_lib_reports(BlendLibReader *reader); /* Blend Expand API * =================== @@ -250,8 +251,10 @@ void BLO_expand_id(BlendExpander *expander, struct ID *id); * =================== */ -void BLO_reportf_wrap(struct ReportList *reports, ReportType type, const char *format, ...) - ATTR_PRINTF_FORMAT(3, 4); +void BLO_reportf_wrap(struct BlendFileReadReport *reports, + ReportType type, + const char *format, + ...) ATTR_PRINTF_FORMAT(3, 4); #ifdef __cplusplus } |