[Bf-blender-cvs] [7cecb81e193] blender-v3.1-release: Fix T96705: Crash when pressing F3 outside a Blender window if Developer extras

Julian Eisel noreply at git.blender.org
Thu Mar 24 09:07:13 CET 2022


Commit: 7cecb81e193f625ce698806ba36eaee4118240c3
Author: Julian Eisel
Date:   Tue Mar 22 18:35:28 2022 +0100
Branches: blender-v3.1-release
https://developer.blender.org/rB7cecb81e193f625ce698806ba36eaee4118240c3

Fix T96705: Crash when pressing F3 outside a Blender window if Developer extras

If the mouse is not hovering the window, there is no active region. This is a
valid state, but the UI-list filter operator didn't account for that case.

===================================================================

M	source/blender/editors/interface/interface_ops.c

===================================================================

diff --git a/source/blender/editors/interface/interface_ops.c b/source/blender/editors/interface/interface_ops.c
index ed512f510e7..947aa1f477e 100644
--- a/source/blender/editors/interface/interface_ops.c
+++ b/source/blender/editors/interface/interface_ops.c
@@ -1989,6 +1989,9 @@ static void UI_OT_drop_name(wmOperatorType *ot)
 static bool ui_list_focused_poll(bContext *C)
 {
   const ARegion *region = CTX_wm_region(C);
+  if (!region) {
+    return false;
+  }
   const wmWindow *win = CTX_wm_window(C);
   const uiList *list = UI_list_find_mouse_over(region, win->eventstate);



More information about the Bf-blender-cvs mailing list