From dc8a43c8755a5e880ff40765f878bf002a38096a Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Fri, 16 Apr 2021 12:06:26 +1000 Subject: Fix RNA enum item callbacks not checking for NULL context The NULL context is used to extract items for document generation. --- source/blender/editors/space_outliner/outliner_edit.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'source/blender/editors/space_outliner/outliner_edit.c') diff --git a/source/blender/editors/space_outliner/outliner_edit.c b/source/blender/editors/space_outliner/outliner_edit.c index 7fe66b017a4..0c97fdc1c18 100644 --- a/source/blender/editors/space_outliner/outliner_edit.c +++ b/source/blender/editors/space_outliner/outliner_edit.c @@ -665,6 +665,10 @@ static const EnumPropertyItem *outliner_id_itemf(bContext *C, PropertyRNA *UNUSED(prop), bool *r_free) { + if (C == NULL) { + return DummyRNA_NULL_items; + } + EnumPropertyItem item_tmp = {0}, *item = NULL; int totitem = 0; int i = 0; -- cgit v1.2.3