Title: [181787] trunk/Source/WebCore
Revision
181787
Author
carlo...@webkit.org
Date
2015-03-20 01:04:37 -0700 (Fri, 20 Mar 2015)

Log Message

[GTK] Crash due to empty drag image during drag-and-drop
https://bugs.webkit.org/show_bug.cgi?id=142671

Reviewed by Philippe Normand.

Return early from ImageBuffer constructor if an empty size is
given. This is a speculative fix for a crash while starting a drag
and drop operation, that I haven't been able to reproduce.

* platform/graphics/cairo/ImageBufferCairo.cpp:
(WebCore::ImageBuffer::ImageBuffer):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (181786 => 181787)


--- trunk/Source/WebCore/ChangeLog	2015-03-20 08:02:13 UTC (rev 181786)
+++ trunk/Source/WebCore/ChangeLog	2015-03-20 08:04:37 UTC (rev 181787)
@@ -1,3 +1,17 @@
+2015-03-20  Carlos Garcia Campos  <cgar...@igalia.com>
+
+        [GTK] Crash due to empty drag image during drag-and-drop
+        https://bugs.webkit.org/show_bug.cgi?id=142671
+
+        Reviewed by Philippe Normand.
+
+        Return early from ImageBuffer constructor if an empty size is
+        given. This is a speculative fix for a crash while starting a drag
+        and drop operation, that I haven't been able to reproduce.
+
+        * platform/graphics/cairo/ImageBufferCairo.cpp:
+        (WebCore::ImageBuffer::ImageBuffer):
+
 2015-03-19  Chris Dumez  <cdu...@apple.com>
 
         [WK2] We should allow stale content when restoring a killed / crashed WebProcess

Modified: trunk/Source/WebCore/platform/graphics/cairo/ImageBufferCairo.cpp (181786 => 181787)


--- trunk/Source/WebCore/platform/graphics/cairo/ImageBufferCairo.cpp	2015-03-20 08:02:13 UTC (rev 181786)
+++ trunk/Source/WebCore/platform/graphics/cairo/ImageBufferCairo.cpp	2015-03-20 08:04:37 UTC (rev 181787)
@@ -101,6 +101,8 @@
     , m_logicalSize(size)
 {
     success = false;  // Make early return mean error.
+    if (m_size.isEmpty())
+        return;
 
 #if ENABLE(ACCELERATED_2D_CANVAS)
     if (renderingMode == Accelerated)
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to