From 5caa74ebf3990b3f70ebb5d46c502802e14e3fa1 Mon Sep 17 00:00:00 2001 From: Bastien Montagne Date: Mon, 11 Nov 2024 11:42:13 +0100 Subject: [PATCH] Fix (unreported) mistake in code, leading to invalid memory access. --- source/blender/blenkernel/intern/blendfile.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/blender/blenkernel/intern/blendfile.cc b/source/blender/blenkernel/intern/blendfile.cc index cf781bd24dc..b53088fb977 100644 --- a/source/blender/blenkernel/intern/blendfile.cc +++ b/source/blender/blenkernel/intern/blendfile.cc @@ -523,7 +523,7 @@ static void unpin_file_local_grease_pencil_brush_materials(const ReuseOldBMainDa const Brush *brush = reinterpret_cast(old_id_iter); if (brush->gpencil_settings && brush->gpencil_settings->material && /* Don't unpin if this material is linked, then it can be preserved for the new file. */ - !ID_IS_LINKED(&brush->gpencil_settings->material)) + !ID_IS_LINKED(brush->gpencil_settings->material)) { /* Unpin material and clear pointer. */ brush->gpencil_settings->flag &= ~GP_BRUSH_MATERIAL_PINNED;