Application crash with CEF 89.0.17

Having problems with building or using CEF's C/C++ APIs? This forum is here to help. Please do not post bug reports or feature requests here.

Application crash with CEF 89.0.17

Postby codergonenuts » Sun Apr 25, 2021 11:45 pm

Hi Team,

I have a Winforms application RabbitWebNote.exe that uses 4 CEF browser instances to show 4 different pages in a 2x2 split-screen mode.
However, I upgraded this app to .Net5 and use the latest released version of CEFSharp, which is 89.0.17.0 from the Nuget package manager.
The libraries that I am using are:
cefsharp.common.netcore\89.0.170\
cefsharp.winforms.netcore\89.0.170\

I have been seeing random crashes to the application with the following errors in the crash dump:
Code: Select all
Dump Summary
------------
Dump File:   RabbitWebNote.exe.18456.dmp : D:\BitCoinTrade\RabbitWebNote\log\CrashDump\RabbitWebNote.exe.18456.dmp
Last Write Time:   4/25/2021 4:43:22 AM
Process Name:   RabbitWebNote.exe : D:\BitCoinTrade\RabbitWebNote\RabbitWebNote.exe
Process Architecture:   x64
Exception Code:   0xC0000005
Exception Information:   The thread tried to read from or write to a virtual address for which it does not have the appropriate access.
Heap Information:   Present

System Information
------------------
OS Version:   10.0.19041
CLR Version(s):   5.0.521.16609


Call stack

Code: Select all
libcef.dll!CefBrowserInfo::RemoveFrame(content::RenderFrameHost * host) Line 154
   at Y:\work\CEF3_git\chromium\src\cef\libcef\browser\browser_info.cc(154)
libcef.dll!extensions::CefMimeHandlerViewGuestDelegate::OnGuestDetached() Line 62
   at Y:\work\CEF3_git\chromium\src\cef\libcef\browser\extensions\mime_handler_view_guest_delegate.cc(62)
libcef.dll!guest_view::GuestViewBase::Destroy(bool also_delete) Line 451
   at Y:\work\CEF3_git\chromium\src\components\guest_view\browser\guest_view_base.cc(451)
[Inline Frame] libcef.dll!content::WebContentsImpl::RenderFrameDeleted::<unnamed-tag>::operator()(content::WebContentsObserver * observer) Line 6455
   at Y:\work\CEF3_git\chromium\src\content\browser\web_contents\web_contents_impl.cc(6455)
[Inline Frame] libcef.dll!content::WebContentsImpl::WebContentsObserverList::ForEachObserver(const content::WebContentsImpl::RenderFrameDeleted::<unnamed-tag> & callable) Line 1452
   at Y:\work\CEF3_git\chromium\src\content\browser\web_contents\web_contents_impl.h(1452)
libcef.dll!content::WebContentsImpl::RenderFrameDeleted(content::RenderFrameHost * render_frame_host) Line 6454
   at Y:\work\CEF3_git\chromium\src\content\browser\web_contents\web_contents_impl.cc(6454)
libcef.dll!content::RenderFrameHostImpl::~RenderFrameHostImpl() Line 1173
   at Y:\work\CEF3_git\chromium\src\content\browser\renderer_host\render_frame_host_impl.cc(1173)
libcef.dll!content::RenderFrameHostImpl::~RenderFrameHostImpl() Line 1135
   at Y:\work\CEF3_git\chromium\src\content\browser\renderer_host\render_frame_host_impl.cc(1135)
[Inline Frame] libcef.dll!std::__1::default_delete<content::RenderFrameHostImpl>::operator()(content::RenderFrameHostImpl * __ptr) Line 2378
   at Y:\work\CEF3_git\chromium\src\buildtools\third_party\libc++\trunk\include\memory(2378)
[Inline Frame] libcef.dll!std::__1::unique_ptr<content::RenderFrameHostImpl,std::default_delete<content::RenderFrameHostImpl>>::reset(content::RenderFrameHostImpl * __p) Line 2633
   at Y:\work\CEF3_git\chromium\src\buildtools\third_party\libc++\trunk\include\memory(2633)
[Inline Frame] libcef.dll!std::__1::unique_ptr<content::RenderFrameHostImpl,std::default_delete<content::RenderFrameHostImpl>>::~unique_ptr() Line 2587
   at Y:\work\CEF3_git\chromium\src\buildtools\third_party\libc++\trunk\include\memory(2587)
libcef.dll!content::RenderFrameHostManager::~RenderFrameHostManager() Line 217
   at Y:\work\CEF3_git\chromium\src\content\browser\renderer_host\render_frame_host_manager.cc(217)
libcef.dll!content::FrameTreeNode::~FrameTreeNode() Line 225
   at Y:\work\CEF3_git\chromium\src\content\browser\renderer_host\frame_tree_node.cc(225)
[Inline Frame] libcef.dll!std::__1::default_delete<content::FrameTreeNode>::operator()(content::FrameTreeNode * __ptr) Line 2378
   at Y:\work\CEF3_git\chromium\src\buildtools\third_party\libc++\trunk\include\memory(2378)
[Inline Frame] libcef.dll!std::__1::unique_ptr<content::FrameTreeNode,std::default_delete<content::FrameTreeNode>>::reset(content::FrameTreeNode * __p) Line 2633
   at Y:\work\CEF3_git\chromium\src\buildtools\third_party\libc++\trunk\include\memory(2633)
libcef.dll!content::RenderFrameHostImpl::RemoveChild(content::FrameTreeNode * child) Line 2951
   at Y:\work\CEF3_git\chromium\src\content\browser\renderer_host\render_frame_host_impl.cc(2951)
libcef.dll!blink::mojom::LocalFrameHostStubDispatch::Accept(blink::mojom::LocalFrameHost * impl, mojo::Message * message) Line 5889
   at Y:\work\CEF3_git\chromium\src\out\Release_GN_x64\gen\third_party\blink\public\mojom\frame\frame.mojom.cc(5889)
libcef.dll!mojo::InterfaceEndpointClient::HandleValidatedMessage(mojo::Message * message) Line 557
   at Y:\work\CEF3_git\chromium\src\mojo\public\cpp\bindings\lib\interface_endpoint_client.cc(557)
libcef.dll!mojo::MessageDispatcher::Accept(mojo::Message * message) Line 46
   at Y:\work\CEF3_git\chromium\src\mojo\public\cpp\bindings\lib\message_dispatcher.cc(46)
libcef.dll!IPC::`anonymous namespace'::ChannelAssociatedGroupController::AcceptOnProxyThread(mojo::Message message) Line 945
   at Y:\work\CEF3_git\chromium\src\ipc\ipc_mojo_bootstrap.cc(945)
[Inline Frame] libcef.dll!base::internal::FunctorTraits<void (IPC::(anonymous namespace)::ChannelAssociatedGroupController::*)(mojo::Message),void>::Invoke(void(IPC::`anonymous namespace'::ChannelAssociatedGroupController::*)(mojo::Message) method, scoped_refptr<IPC::(anonymous namespace)::ChannelAssociatedGroupController> && receiver_ptr, mojo::Message && args) Line 498
   at Y:\work\CEF3_git\chromium\src\base\bind_internal.h(498)
[Inline Frame] libcef.dll!base::internal::InvokeHelper<0,void>::MakeItSo(void(IPC::`anonymous namespace'::ChannelAssociatedGroupController::*)(mojo::Message) && functor, scoped_refptr<IPC::(anonymous namespace)::ChannelAssociatedGroupController> && args, mojo::Message && args) Line 637
   at Y:\work\CEF3_git\chromium\src\base\bind_internal.h(637)
[Inline Frame] libcef.dll!base::internal::Invoker<base::internal::BindState<void (IPC::(anonymous namespace)::ChannelAssociatedGroupController::*)(mojo::Message),scoped_refptr<IPC::(anonymous namespace)::ChannelAssociatedGroupController>,mojo::Message>,void ()>::RunImpl(void(IPC::`anonymous namespace'::ChannelAssociatedGroupController::*)(mojo::Message) && functor, std::__1::tuple<scoped_refptr<IPC::(anonymous namespace)::ChannelAssociatedGroupController>,mojo::Message> && bound, std::__1::integer_sequence<unsigned long long,0,1>) Line 710
   at Y:\work\CEF3_git\chromium\src\base\bind_internal.h(710)
libcef.dll!base::internal::Invoker<base::internal::BindState<void (IPC::(anonymous namespace)::ChannelAssociatedGroupController::*)(mojo::Message),scoped_refptr<IPC::(anonymous namespace)::ChannelAssociatedGroupController>,mojo::Message>,void ()>::RunOnce(base::internal::BindStateBase * base) Line 679
   at Y:\work\CEF3_git\chromium\src\base\bind_internal.h(679)
[Inline Frame] libcef.dll!base::OnceCallback<void ()>::Run() Line 101
   at Y:\work\CEF3_git\chromium\src\base\callback.h(101)
libcef.dll!base::TaskAnnotator::RunTask(const char * trace_event_name, base::PendingTask * pending_task) Line 163
   at Y:\work\CEF3_git\chromium\src\base\task\common\task_annotator.cc(163)
libcef.dll!base::sequence_manager::internal::ThreadControllerWithMessagePumpImpl::DoWorkImpl(base::sequence_manager::LazyNow * continuation_lazy_now) Line 352
   at Y:\work\CEF3_git\chromium\src\base\task\sequence_manager\thread_controller_with_message_pump_impl.cc(352)
libcef.dll!base::sequence_manager::internal::ThreadControllerWithMessagePumpImpl::DoWork() Line 266
   at Y:\work\CEF3_git\chromium\src\base\task\sequence_manager\thread_controller_with_message_pump_impl.cc(266)
libcef.dll!base::MessagePumpForUI::DoRunLoop() Line 226
   at Y:\work\CEF3_git\chromium\src\base\message_loop\message_pump_win.cc(226)
libcef.dll!base::MessagePumpWin::Run(base::MessagePump::Delegate * delegate) Line 83
   at Y:\work\CEF3_git\chromium\src\base\message_loop\message_pump_win.cc(83)
libcef.dll!base::sequence_manager::internal::ThreadControllerWithMessagePumpImpl::Run(bool application_tasks_allowed, base::TimeDelta timeout) Line 463
   at Y:\work\CEF3_git\chromium\src\base\task\sequence_manager\thread_controller_with_message_pump_impl.cc(463)
libcef.dll!base::RunLoop::Run() Line 133
   at Y:\work\CEF3_git\chromium\src\base\run_loop.cc(133)
libcef.dll!CefMainRunner::RunMessageLoop() Line 288
   at Y:\work\CEF3_git\chromium\src\cef\libcef\browser\main_runner.cc(288)
libcef.dll!CefUIThread::ThreadMain() Line 184
   at Y:\work\CEF3_git\chromium\src\cef\libcef\browser\main_runner.cc(184)
libcef.dll!base::`anonymous namespace'::ThreadFunc(void * params) Line 103
   at Y:\work\CEF3_git\chromium\src\base\threading\platform_thread_win.cc(103)
[External Code]


Please help me to identify the problem here, I have tested this app both with 32-bit and 64-bit versions, both crash after a while.

Thank in Advance!

Regards,
CGN
codergonenuts
Newbie
 
Posts: 5
Joined: Sun Apr 25, 2021 9:33 pm

Re: Application crash with CEF 89.0.17

Postby magreenblatt » Mon Apr 26, 2021 9:34 am

What content are you loading? Can you reproduce the crash with the CEF sample applications?
magreenblatt
Site Admin
 
Posts: 10858
Joined: Fri May 29, 2009 6:57 pm

Re: Application crash with CEF 89.0.17

Postby codergonenuts » Mon Apr 26, 2021 10:42 am

these were the 4 URLs app was displaying on 4 separate instances of the browser when it crashed.

Url [0] = "https://www.hbg.com/en-us/exchange/arpa_usdt"
Url [1] = "https://futures.kucoin.com/trade/SOLUSDTM"
Url [2] = "https://prime.coinbase.com/trade/MATIC-BTC"
Url [3] = "https://ftx.com/trade/SOL-PERP"

However, I have reproduced this crash problem with another set of URLs as well.
example:
Url [0] = "https://www.gopax.co.kr/exchange/btc-krw"
Url [1] = "https://www.okex.com/spot/full/dora-usdt"
Url [2] = "https://www.binance.com/en/delivery/ethusd_perpetual"
Url [3] = "http://13.211.36.80:8001/machine-view"

I do not think this is URL specific.

I tried these URLs on the sample App (with 1 browser instance), it did not crash.
codergonenuts
Newbie
 
Posts: 5
Joined: Sun Apr 25, 2021 9:33 pm

Re: Application crash with CEF 89.0.17

Postby magreenblatt » Mon Apr 26, 2021 10:56 am

Do you just load those URLs and leave them running, or do you interact with them in some way?
magreenblatt
Site Admin
 
Posts: 10858
Joined: Fri May 29, 2009 6:57 pm

Re: Application crash with CEF 89.0.17

Postby ndesktop » Mon Apr 26, 2021 12:37 pm

Maybe similar to 1161035 chromium issue.
ndesktop
Master
 
Posts: 538
Joined: Thu Dec 03, 2015 10:10 am

Re: Application crash with CEF 89.0.17

Postby codergonenuts » Mon Apr 26, 2021 12:37 pm

No, we don't interact with the pages, just keep them running.
just load a new URL when the server sends an update.
codergonenuts
Newbie
 
Posts: 5
Joined: Sun Apr 25, 2021 9:33 pm

Re: Application crash with CEF 89.0.17

Postby codergonenuts » Tue Apr 27, 2021 10:47 pm

Let me know if you need more information.
I am not very sure how the issue https://bugs.chromium.org/p/chromium/issues/detail?id=1161035&q=WebContentsImpl%3A%3ARenderFrameDeleted%20foreachobserver&can=1 is related to mine.
Stack trace seems to be different.
codergonenuts
Newbie
 
Posts: 5
Joined: Sun Apr 25, 2021 9:33 pm

Re: Application crash with CEF 89.0.17

Postby amaitland » Tue Apr 27, 2021 10:53 pm

Please test with version `90.5.70-pre`. It's now available on Nuget.org
Maintainer of the CefSharp project.
amaitland
Master
 
Posts: 926
Joined: Wed Jan 14, 2015 2:35 am

Re: Application crash with CEF 89.0.17

Postby codergonenuts » Sat May 01, 2021 3:31 am

amaitland wrote:Please test with version `90.5.70-pre`. It's now available on Nuget.org


tried this version as well, it still crashes with the same error. and this problem happens on different machines as well. It is not machine-specific.
codergonenuts
Newbie
 
Posts: 5
Joined: Sun Apr 25, 2021 9:33 pm

Re: Application crash with CEF 89.0.17

Postby amaitland » Sat May 01, 2021 4:47 am

You can try removing the disable-site-isolation-trials command line arg which is set by default in CefSharp.

https://github.com/cefsharp/CefSharp/bl ... Base.h#L55


Code: Select all
settings.CefCommandLineArgs.Remove("disable-site-isolation-trials");
Maintainer of the CefSharp project.
amaitland
Master
 
Posts: 926
Joined: Wed Jan 14, 2015 2:35 am


Return to Support Forum

Who is online

Users browsing this forum: Google [Bot], prsolucoes and 15 guests