crash or assert on shutdown

559 views
Skip to first unread message

Alex B

unread,
May 30, 2012, 4:35:05 PM5/30/12
to cefs...@googlegroups.com

Hey there,


I've noticed that with the latest CEF versions, when I quit our C# app there's a crash in the CEF.dll. It happens somewhere in it, it's hard to tell why though. Here's the stack:

> KernelBase.dll!757a9617() 

  [Frames below may be incorrect and/or missing, no symbols loaded for KernelBase.dll]

  KernelBase.dll!757a9617() 

  mscorwks.dll!67f572f9() 

  mscorwks.dll!67ee67c9() 

  mscorwks.dll!67d31aaa() 

  CefSharp.dll!CefCppToC<CefClientCppToC,CefClient,_cef_client_t>::UnderlyingRelease()  + 0x4a bytes

  CefSharp.dll!CefCppToC<CefClientCppToC,CefClient,_cef_client_t>::UnderlyingRelease()  + 0x4a bytes

  mscorwks.dll!67d3c05c() 



That is, without trying to call CEF.Shutdown. If I call shutdown, I'm getting an assertion failed in 

.\libcef_dll\wrapper\lib_cef_wrapper.cc, line 144

Expression CefRequestCToCpp::DebugObjCt == 0


I've noticed that the sample example from your github project doesn't actually crash, but rather hangs in the web view.dispose. It doesn't call CEF.Shutdown either.

I assume it's related, and was wondering if you knew why that happens and how to prevent it?


The first crash doesn't happen all the time. The assert happens all the time if I call CEF.shutdown. Am I not supposed to call it?


Thanks for all the help you could provide.

Alex B

unread,
Jun 1, 2012, 2:34:38 PM6/1/12
to cefs...@googlegroups.com
It's definitely something that happens when I try to close the browser while the page is still loading.
In the latest github version of CEFSharp, right after you run the winforms example and while the page is still loading (it still says 'stop' on the rightmost top button), if I try to close the app then it hangs. I can repro all the time.

Alex B

unread,
Jun 26, 2012, 6:25:46 AM6/26/12
to cefs...@googlegroups.com
FYI I fixed it by calling StopLoad in ClientAdapter::OnBeforeClose - keeping a BOOL state to return right away in OnLoadEnd to prevent a deadlock.

Rez H

unread,
Jul 24, 2014, 4:01:45 PM7/24/14
to cefs...@googlegroups.com, zef...@gmail.com
Seeing the same issue as you and trying to implement your fix. I know this is a two year old thread, but if you're still around, can you perhaps elaborate a bit about your fix? I'm not as sharp on the C++ side of CefSharp.
Reply all
Reply to author
Forward
0 new messages