Fix potential UAF of CefBPDNativeAura::window_widget_

This commit is contained in:
Marshall Greenblatt
2023-02-06 15:43:00 -08:00
parent adfa59f690
commit f34406c57d
6 changed files with 48 additions and 10 deletions

View File

@ -284,7 +284,8 @@ bool CefBrowserPlatformDelegateNativeWin::CreateHostWindow() {
(top_level_window_ex_styles & WS_EX_TOPMOST) == WS_EX_TOPMOST;
CefWindowDelegateView* delegate_view = new CefWindowDelegateView(
GetBackgroundColor(), always_on_top, GetBoundsChangedCallback());
GetBackgroundColor(), always_on_top, GetBoundsChangedCallback(),
GetWidgetDeleteCallback());
delegate_view->Init(window_info_.window, web_contents_,
gfx::Rect(0, 0, dip_rect.width(), dip_rect.height()));
@ -702,4 +703,4 @@ LRESULT CALLBACK CefBrowserPlatformDelegateNativeWin::WndProc(HWND hwnd,
}
return DefWindowProc(hwnd, message, wParam, lParam);
}
}