[SCM] WebKit Debian packaging branch, webkit-1.2, updated. upstream/1.1.90-6072-g9a69373

eric at webkit.org eric at webkit.org
Thu Apr 8 00:06:44 UTC 2010


The following commit has been merged in the webkit-1.2 branch:
commit ac15d2112bdbfc8b07d0d537b7a1c28541ba4197
Author: eric at webkit.org <eric at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Tue Dec 1 15:45:23 2009 +0000

    2009-12-01  Mads Ager  <ager at chromium.org>
    
            Reviewed by Eric Seidel.
    
            [V8] Don't crash in DOMWindow event getter in OOM situations
            https://bugs.webkit.org/show_bug.cgi?id=32017
    
            Add missing null handle checks in DOMWindow event property
            accessors.  V8Proxy::context(frame) can return a null handle in
            OOM situations either if failing to initialize a context or if an
            OOM is handled gracefully and javascript is disabled.
    
            No new tests because we don't have a good way to test
            out-of-memory bugs.
    
            * bindings/v8/custom/V8DOMWindowCustom.cpp:
            (WebCore::ACCESSOR_GETTER):
            (WebCore::ACCESSOR_SETTER):
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@51536 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 0a0125a..a839823 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,22 @@
+2009-12-01  Mads Ager  <ager at chromium.org>
+
+        Reviewed by Eric Seidel.
+
+        [V8] Don't crash in DOMWindow event getter in OOM situations
+        https://bugs.webkit.org/show_bug.cgi?id=32017
+
+        Add missing null handle checks in DOMWindow event property
+        accessors.  V8Proxy::context(frame) can return a null handle in
+        OOM situations either if failing to initialize a context or if an
+        OOM is handled gracefully and javascript is disabled.
+
+        No new tests because we don't have a good way to test
+        out-of-memory bugs.
+
+        * bindings/v8/custom/V8DOMWindowCustom.cpp:
+        (WebCore::ACCESSOR_GETTER):
+        (WebCore::ACCESSOR_SETTER):
+
 2009-12-01  Chris Marrin  <cmarrin at apple.com>
 
         Reviewed by Oliver Hunt.
diff --git a/WebCore/bindings/v8/custom/V8DOMWindowCustom.cpp b/WebCore/bindings/v8/custom/V8DOMWindowCustom.cpp
index 7106971..3672f7c 100644
--- a/WebCore/bindings/v8/custom/V8DOMWindowCustom.cpp
+++ b/WebCore/bindings/v8/custom/V8DOMWindowCustom.cpp
@@ -175,6 +175,9 @@ ACCESSOR_GETTER(DOMWindowEvent)
         return v8::Undefined();
 
     v8::Local<v8::Context> context = V8Proxy::context(frame);
+    if (context.IsEmpty())
+        return v8::Undefined();
+
     v8::Local<v8::String> eventSymbol = v8::String::NewSymbol("event");
     v8::Handle<v8::Value> jsEvent = context->Global()->GetHiddenValue(eventSymbol);
     if (jsEvent.IsEmpty())
@@ -193,6 +196,9 @@ ACCESSOR_SETTER(DOMWindowEvent)
         return;
 
     v8::Local<v8::Context> context = V8Proxy::context(frame);
+    if (context.IsEmpty())
+        return;
+
     v8::Local<v8::String> eventSymbol = v8::String::NewSymbol("event");
     context->Global()->SetHiddenValue(eventSymbol, value);
 }

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list