[SCM] WebKit Debian packaging branch, debian/unstable, updated. debian/1.1.15-1-40151-g37bb677

rjw rjw at 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Sat Sep 26 08:47:34 UTC 2009


The following commit has been merged in the debian/unstable branch:
commit 0202e9ca5b0f7a1689ca86b74389ec20c65c7b71
Author: rjw <rjw at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Thu Jun 17 18:24:46 2004 +0000

    	Fixed <rdar://problem/3698867> setting the canvas or parent to display:none and updating the causes a nil-deref
    
    	Ensured that we have a renderer before rendering.
    
            Reviewed by John.
    
            * khtml/ecma/kjs_html.cpp:
            (KJS::Context2DFunction::tryCall):
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@6878 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebCore/ChangeLog-2005-08-23 b/WebCore/ChangeLog-2005-08-23
index 271ae1e..3a7f16d 100644
--- a/WebCore/ChangeLog-2005-08-23
+++ b/WebCore/ChangeLog-2005-08-23
@@ -1,3 +1,14 @@
+2004-06-17  Richard Williamson   <rjw at apple.com>
+
+	Fixed <rdar://problem/3698867> setting the canvas or parent to display:none and updating the causes a nil-deref
+
+	Ensured that we have a renderer before rendering.
+
+        Reviewed by John.
+
+        * khtml/ecma/kjs_html.cpp:
+        (KJS::Context2DFunction::tryCall):
+
 2004-06-17  David Hyatt  <hyatt at apple.com>
 
 	Fix for 3674601, "Read More..." links should trail articles in Emerson.
diff --git a/WebCore/khtml/ecma/kjs_html.cpp b/WebCore/khtml/ecma/kjs_html.cpp
index f306ed8..7038505 100644
--- a/WebCore/khtml/ecma/kjs_html.cpp
+++ b/WebCore/khtml/ecma/kjs_html.cpp
@@ -3357,8 +3357,13 @@ Value KJS::Context2DFunction::tryCall(ExecState *exec, Object &thisObj, const Li
 
     Context2D *contextObject = static_cast<KJS::Context2D *>(thisObj.imp());
     khtml::RenderCanvasImage *renderer = static_cast<khtml::RenderCanvasImage*>(contextObject->_element->renderer());
-    CGContextRef drawingContext = renderer->drawingContext();
+    if (!renderer)
+        return Undefined();
 
+    CGContextRef drawingContext = renderer->drawingContext();
+    if (!drawingContext)
+        return Undefined();
+    
     switch (id) {
         case Context2D::Save: {
             if (args.size() != 0) {

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list