From 64aa6c68d5324f30338172316643b8a50b0971b9 Mon Sep 17 00:00:00 2001 From: Jacques Lucke Date: Mon, 16 Nov 2020 11:30:24 +0100 Subject: Fix T81817: use-after-free when trying to open file from splash screen The issues was that Blender was trying to refresh the splash screen region. However, opening the file browser closed the splash screen and freed the region. The fix is to simply not refresh the region. Has been approved in T81817. --- source/blender/windowmanager/intern/wm_splash_screen.c | 7 ------- 1 file changed, 7 deletions(-) (limited to 'source/blender/windowmanager') diff --git a/source/blender/windowmanager/intern/wm_splash_screen.c b/source/blender/windowmanager/intern/wm_splash_screen.c index ec1c4440474..d732393b631 100644 --- a/source/blender/windowmanager/intern/wm_splash_screen.c +++ b/source/blender/windowmanager/intern/wm_splash_screen.c @@ -72,12 +72,6 @@ static void wm_block_close(bContext *C, void *arg_block, void *UNUSED(arg)) UI_popup_block_close(C, win, arg_block); } -static void wm_block_splash_refreshmenu(bContext *C, void *UNUSED(arg_block), void *UNUSED(arg)) -{ - ARegion *region_menu = CTX_wm_menu(C); - ED_region_tag_refresh_ui(region_menu); -} - static void wm_block_splash_add_label(uiBlock *block, const char *label, int x, int y) { if (!(label && label[0])) { @@ -217,7 +211,6 @@ static uiBlock *wm_block_create_splash(bContext *C, ARegion *region, void *UNUSE block, ibuf, 0, 0.5f * U.widget_unit, splash_width, splash_height, NULL); UI_but_func_set(but, wm_block_close, block, NULL); - UI_block_func_set(block, wm_block_splash_refreshmenu, block, NULL); wm_block_splash_add_label( block, BKE_blender_version_string(), splash_width, splash_height - 13.0 * U.dpi_fac); -- cgit v1.2.3