Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBastien Montagne <bastien@blender.org>2021-06-24 11:53:45 +0300
committerBastien Montagne <bastien@blender.org>2021-06-24 13:10:06 +0300
commit8cdb99d51c02d5cc60c774c176a43519c046e14c (patch)
tree0185df926bf3c14905d51a648c1d155cccc4dce1 /source/blender/windowmanager/intern/wm_files_link.c
parent3a8347f82348ef2f430cdaa8a2e840ad3dba5a71 (diff)
Fix linking code after own recent commit.
More stupid mistake in recent enhanced reports for file load code, rB82c17082ba0e left some read-after-free situations.
Diffstat (limited to 'source/blender/windowmanager/intern/wm_files_link.c')
-rw-r--r--source/blender/windowmanager/intern/wm_files_link.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/source/blender/windowmanager/intern/wm_files_link.c b/source/blender/windowmanager/intern/wm_files_link.c
index f938c507818..fec5a516688 100644
--- a/source/blender/windowmanager/intern/wm_files_link.c
+++ b/source/blender/windowmanager/intern/wm_files_link.c
@@ -239,12 +239,14 @@ static void wm_link_do(WMLinkAppendData *lapp_data,
for (lib_idx = 0, liblink = lapp_data->libraries.list; liblink;
lib_idx++, liblink = liblink->next) {
char *libname = liblink->link;
+ BlendFileReadReport bf_reports = {.reports = reports};
if (STREQ(libname, BLO_EMBEDDED_STARTUP_BLEND)) {
- bh = BLO_blendhandle_from_memory(datatoc_startup_blend, datatoc_startup_blend_size);
+ bh = BLO_blendhandle_from_memory(
+ datatoc_startup_blend, datatoc_startup_blend_size, &bf_reports);
}
else {
- bh = BLO_blendhandle_from_file(libname, &(BlendFileReadReport){.reports = reports});
+ bh = BLO_blendhandle_from_file(libname, &bf_reports);
}
if (bh == NULL) {