Crash + dump - reproducible

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.

Re: Crash + dump - reproducible

Postby chrisaraman » Tue May 10, 2016 5:08 pm

I believe I've identified the root cause of this crash. It's a bug in Chromium, but Chromium itself won't hit the bug. CEF hits the bug because of how it uses WebCursor.

The bug was introduced to Chromium here:
https://chromium.googlesource.com/chrom ... 2287300e3a

The change introduced support for high DPI cursors on Windows. However, it failed to copy the new device_scale_ member when copying a WebCursorInfo. CEF assigns (copies) a WebCursorInfo in CefRenderWidgetHostViewOSR::UpdateCursor.
https://bitbucket.org/chromiumembedded/ ... 93d0465c9f

Because device_scale_ is not initialized when CEF calls WebCursor::GetPlatformCursor, Chromium tries to allocate a potentially very large bitmap, leading to the out of memory exception.

It seems like the potential workarounds are to:
- avoid using custom cursors in CSS, or
- avoid registering an IRenderHandler with CEF, however this isn't possible for users of wrappers like CefSharp, which always register a handler

I'm not aware of any command line flags to disable custom cursors in Chromium.
http://peter.sh/experiments/chromium-co ... -switches/

Because I'm not able to reproduce the issue in Chromium or Chrome, and I found no similar bug reports at crbug.com, I thought it best to follow up here. Would the CEF authors consider including this Chromium patch with CEF? If not, could you provide some guidance as to how best to submit this to Chromium authors without a repro?
Code: Select all
index b8b4c57..69fe05e 100644
--- a/content/common/cursors/webcursor_aurawin.cc
+++ b/content/common/cursors/webcursor_aurawin.cc
@@ -37,6 +37,7 @@ ui::PlatformCursor WebCursor::GetPlatformCursor() {

 void WebCursor::InitPlatformData() {
   custom_cursor_ = NULL;
+  device_scale_factor_ = 1.0f;
 }

 bool WebCursor::SerializePlatformData(base::Pickle* pickle) const {
@@ -59,6 +60,7 @@ void WebCursor::CleanupPlatformData() {
 }

 void WebCursor::CopyPlatformData(const WebCursor& other) {
+  device_scale_factor_ = other.device_scale_factor_;
 }

 }  // namespace content
chrisaraman
Newbie
 
Posts: 2
Joined: Tue May 10, 2016 4:20 pm

Re: Crash + dump - reproducible

Postby chrisaraman » Tue May 10, 2016 9:46 pm

chrisaraman
Newbie
 
Posts: 2
Joined: Tue May 10, 2016 4:20 pm

Previous

Return to Support Forum

Who is online

Users browsing this forum: No registered users and 37 guests