[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-10851-g50815da

commit-queue at webkit.org commit-queue at webkit.org
Wed Dec 22 18:18:08 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit a97d5476b1177247c39c3b773cf24d9c6e50128b
Author: commit-queue at webkit.org <commit-queue at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Thu Dec 9 18:26:54 2010 +0000

    2010-12-09  Yong Li  <yoli at rim.com>
    
            Reviewed by Darin Adler.
    
            Check the return value of ImageBuffer::create()
            to avoid crash when ImageBuffer::create() fails.
            https://bugs.webkit.org/show_bug.cgi?id=50631
    
            No new test because it relies on the platform implementation
            of ImageBuffer. It is hard to make ImageBuffer::create() fail
            in most ports.
    
            * platform/graphics/GeneratedImage.cpp:
            (WebCore::GeneratedImage::drawPattern):
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@73622 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index dc2838e..2a50842 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,18 @@
+2010-12-09  Yong Li  <yoli at rim.com>
+
+        Reviewed by Darin Adler.
+
+        Check the return value of ImageBuffer::create()
+        to avoid crash when ImageBuffer::create() fails.
+        https://bugs.webkit.org/show_bug.cgi?id=50631
+
+        No new test because it relies on the platform implementation
+        of ImageBuffer. It is hard to make ImageBuffer::create() fail
+        in most ports.
+
+        * platform/graphics/GeneratedImage.cpp:
+        (WebCore::GeneratedImage::drawPattern):
+
 2010-12-09  Maciej Stachowiak  <mjs at apple.com>
 
         Reviewed by Dan Bernstein.
diff --git a/WebCore/platform/graphics/GeneratedImage.cpp b/WebCore/platform/graphics/GeneratedImage.cpp
index 5df2608..f2c175b 100644
--- a/WebCore/platform/graphics/GeneratedImage.cpp
+++ b/WebCore/platform/graphics/GeneratedImage.cpp
@@ -57,7 +57,8 @@ void GeneratedImage::drawPattern(GraphicsContext* context, const FloatRect& srcR
 
     // Create a BitmapImage and call drawPattern on it.
     OwnPtr<ImageBuffer> imageBuffer = ImageBuffer::create(adjustedSize);
-    ASSERT(imageBuffer.get());
+    if (!imageBuffer)
+        return;
 
     // Fill with the gradient.
     GraphicsContext* graphicsContext = imageBuffer->context();

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list