diff options
author | Pedro Reis <veryprofessionaldodo> | 2019-10-04 17:55:37 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2019-10-04 17:57:48 +0300 |
commit | eeba31e2ca80863da19624721c2fcf020f13db53 (patch) | |
tree | c6e7ab9f451ca1b7a424b95d0ad3caad0f36b9c7 /source/blender/windowmanager/intern/wm_event_system.c | |
parent | 809ab298f1ca8696b8f997c80da8ddf3ae95b89c (diff) |
Fix T69910: crash when using a hotkey for a new or open recent file
Differential Revision: https://developer.blender.org/D5839
Diffstat (limited to 'source/blender/windowmanager/intern/wm_event_system.c')
-rw-r--r-- | source/blender/windowmanager/intern/wm_event_system.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/source/blender/windowmanager/intern/wm_event_system.c b/source/blender/windowmanager/intern/wm_event_system.c index 1eec08c2e7a..a744cfb8c28 100644 --- a/source/blender/windowmanager/intern/wm_event_system.c +++ b/source/blender/windowmanager/intern/wm_event_system.c @@ -2738,7 +2738,10 @@ static int wm_handlers_do_intern(bContext *C, wmEvent *event, ListBase *handlers /* Clear the tool-tip whenever a key binding is handled, without this tool-tips * are kept when a modal operators starts (annoying but otherwise harmless). */ if (action & WM_HANDLER_BREAK) { - WM_tooltip_clear(C, CTX_wm_window(C)); + /* Window may be gone after file read. */ + if (CTX_wm_window(C) != NULL) { + WM_tooltip_clear(C, CTX_wm_window(C)); + } } } else if (handler_base->type == WM_HANDLER_TYPE_UI) { |