Changeset 122488 in webkit


Ignore:
Timestamp:
Jul 12, 2012 11:31:09 AM (12 years ago)
Author:
commit-queue@webkit.org
Message:

storage tests are flaky (crashing) on windows
https://bugs.webkit.org/show_bug.cgi?id=90469

Patch by James Weatherall <wez@chromium.org> on 2012-07-12
Reviewed by Kentaro Hara.

Add a missing check that the underlying V8 object reference in a V8 NPObject is valid, and zero the NPObject's rootObject member when disposing it, to ensure that it won't be mistakenly touched after that point.

This patch is intended to resolve flakiness in the storage tests including:

storage/indexeddb/mozilla/indexes.html
storage/indexeddb/mozilla/key-requirements-inline-and-passed.html
storage/websql/multiple-databases-garbage-collection.html

  • bindings/v8/NPV8Object.cpp:

(WebCore::disposeUnderlyingV8Object):
Zero the NPObject's underlying rootObject.
(_NPN_EvaluateHelper):
Add check that the underlying V8 object reference is valid.

Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r122484 r122488  
     12012-07-12  James Weatherall  <wez@chromium.org>
     2
     3        storage tests are flaky (crashing) on windows
     4        https://bugs.webkit.org/show_bug.cgi?id=90469
     5
     6        Reviewed by Kentaro Hara.
     7
     8        Add a missing check that the underlying V8 object reference in a V8 NPObject is valid, and zero the NPObject's rootObject member when disposing it, to ensure that it won't be mistakenly touched after that point.
     9
     10        This patch is intended to resolve flakiness in the storage tests including:
     11          storage/indexeddb/mozilla/indexes.html
     12          storage/indexeddb/mozilla/key-requirements-inline-and-passed.html
     13          storage/websql/multiple-databases-garbage-collection.html
     14
     15        * bindings/v8/NPV8Object.cpp:
     16        (WebCore::disposeUnderlyingV8Object):
     17        Zero the NPObject's underlying rootObject.
     18        (_NPN_EvaluateHelper):
     19        Add check that the underlying V8 object reference is valid.
     20
    1212012-07-12  No'am Rosenthal  <noam.rosenthal@nokia.com>
    222
  • trunk/Source/WebCore/bindings/v8/NPV8Object.cpp

    r121610 r122488  
    187187    v8NpObject->v8Object.Dispose();
    188188    v8NpObject->v8Object.Clear();
     189    v8NpObject->rootObject = 0;
    189190}
    190191
     
    320321
    321322    if (npObject->_class != npScriptObjectClass)
     323        return false;
     324    V8NPObject* v8NpObject = reinterpret_cast<V8NPObject*>(npObject);
     325    if (v8NpObject->v8Object.IsEmpty())
    322326        return false;
    323327
Note: See TracChangeset for help on using the changeset viewer.