Closed magreenblatt closed 2 years ago
Issue #3366 was marked as a duplicate of this issue.
This is likely due to the async execution of SetFocusInternal added in issue #3040.
Fix issues with browser focus assignment (fixes issue #3306, fixes issue #3166, see issue #3040)
DesktopWindowTreeHostWin ("Chrome_WidgetWin_0") focus needs to be set synchronously in response to the parent window WM_SETFOCUS message and before the associated call to WebContents::Focus. See updated comments in CefBrowserPlatformDelegateNativeWin::SetFocus.
→ <<cset 21d714ab6e09 (bb)>>
Fix issues with browser focus assignment (fixes issue #3306, fixes issue #3166, see issue #3040)
DesktopWindowTreeHostWin ("Chrome_WidgetWin_0") focus needs to be set synchronously in response to the parent window WM_SETFOCUS message and before the associated call to WebContents::Focus. See updated comments in CefBrowserPlatformDelegateNativeWin::SetFocus.
→ <<cset 08f37697afd7 (bb)>>
Fix issues with browser focus assignment (fixes issue #3306, fixes issue #3166, see issue #3040)
DesktopWindowTreeHostWin ("Chrome_WidgetWin_0") focus needs to be set synchronously in response to the parent window WM_SETFOCUS message and before the associated call to WebContents::Focus. See updated comments in CefBrowserPlatformDelegateNativeWin::SetFocus.
→ <<cset 2587cf23c511 (bb)>>
Original report by Jesse Taber (Bitbucket: Jesse Taber).
This issue presents in v
92.0.16
. It’s possible to get an access violation error if you attempt to focus the browser immediately after it was disposed. This can be observed in the CefSharp Windows Forms example application if you use a keyboard shortcut to close an open browser tab. I was able to get the proper release symbols and generate a crash dump to find a stack trace (see below). It appears that it’s possible to have Chromium returnnullptr
when callingHWNDForWidget
which might be causing the problem?CefSharp Issue Thread: https://github.com/cefsharp/CefSharp/issues/3715
Error Details and stack trace:
Unhandled exception at 0x11F19ED3 (libcef.dll) in ce1a5314 (bb)-6529-4599-a552-2b52910908c2.dmp: 0xC0000005: Access violation reading location 0x2061CF89.