Title: [87366] trunk/Source/WebCore
Revision
87366
Author
[email protected]
Date
2011-05-26 00:15:36 -0700 (Thu, 26 May 2011)

Log Message

2011-05-26  Igor Oliveira  <[email protected]>

        Reviewed by Andreas Kling.

        drag-not-loaded-image.html test crashes when WebKit is built with debug option
        https://bugs.webkit.org/show_bug.cgi?id=61480

        Checks if image has content before starting to drag.

        * page/DragController.cpp:
        (WebCore::DragController::startDrag):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (87365 => 87366)


--- trunk/Source/WebCore/ChangeLog	2011-05-26 07:01:06 UTC (rev 87365)
+++ trunk/Source/WebCore/ChangeLog	2011-05-26 07:15:36 UTC (rev 87366)
@@ -1,3 +1,15 @@
+2011-05-26  Igor Oliveira  <[email protected]>
+
+        Reviewed by Andreas Kling.
+
+        drag-not-loaded-image.html test crashes when WebKit is built with debug option
+        https://bugs.webkit.org/show_bug.cgi?id=61480
+
+        Checks if image has content before starting to drag.
+
+        * page/DragController.cpp:
+        (WebCore::DragController::startDrag):
+
 2011-05-26  Alok Priyadarshi  <[email protected]>
 
         Reviewed by James Robinson.

Modified: trunk/Source/WebCore/page/DragController.cpp (87365 => 87366)


--- trunk/Source/WebCore/page/DragController.cpp	2011-05-26 07:01:06 UTC (rev 87365)
+++ trunk/Source/WebCore/page/DragController.cpp	2011-05-26 07:15:36 UTC (rev 87366)
@@ -731,7 +731,7 @@
             m_dragOffset = IntPoint(dragOrigin.x() - dragLoc.x(), dragOrigin.y() - dragLoc.y());
         }
         doSystemDrag(dragImage, dragLoc, dragOrigin, clipboard, src, false);
-    } else if (!imageURL.isEmpty() && node && node->isElementNode() && image
+    } else if (!imageURL.isEmpty() && node && node->isElementNode() && image && !image->isNull()
                && (m_dragSourceAction & DragSourceActionImage)) {
         // We shouldn't be starting a drag for an image that can't provide an extension.
         // This is an early detection for problems encountered later upon drop.
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to