Blender Git Commit Log

Git Commits -> Revision 57f1379

Revision 57f1379 by Philipp Oeser (master)
October 19, 2021, 14:42 (GMT)
Fix T92265: Outliner crash clicking override warning buttons

`outliner_draw_overrides_buts` uses `uiDefIconBlockBut` but doing so
without defining a function callback to actually build a block.
This will make the button go down the route of spawning a popup, but
without a menu. Crash then happens later accesing the (missing) menu in
`ui_handler_region_menu`.

So while we could dive into making this usage failsafe (carefully
checking `BUTTON_STATE_MENU_OPEN` in combination with
`uiHandleButtonData->menu` being NULL all over), but it seems much more
straightforward to just use `uiDefIconBut` (instead of
`uiDefIconBlockBut`) since this Override Warning buttons seem not to
intend spawning a menu anyways?

Maniphest Tasks: T92265

Differential Revision: https://developer.blender.org/D12917

Commit Details:

Full Hash: 57f1379104e7e36dd60fc270253e4a4555f0e699
Parent Commit: b3b7319
Lines Changed: +14, -10

1 Modified Path:

/source/blender/editors/space_outliner/outliner_draw.c (+14, -10) (Diff)
By: Miika HämäläinenLast update: Nov-07-2014 14:18MiikaHweb | 2003-2021