Changeset 76373 in webkit


Ignore:
Timestamp:
Jan 21, 2011 11:40:02 AM (13 years ago)
Author:
antonm@chromium.org
Message:

2011-01-21 Anton Muhin <antonm@chromium.org>

Reviewed by Nate Chapin.

[v8] Properly deal with the case when conversion to string throws an exception for HTMLCollection accessors
https://bugs.webkit.org/show_bug.cgi?id=52901

  • fast/dom/htmlcollection-conversion-throws-exception-expected.txt: Added.
  • fast/dom/htmlcollection-conversion-throws-exception.html: Added.

2011-01-21 Anton Muhin <antonm@chromium.org>

Reviewed by Nate Chapin.

[v8] Properly deal with the case when conversion to string throws an exception for HTMLCollection accessors
https://bugs.webkit.org/show_bug.cgi?id=52901

Test: fast/dom/htmlcollection-conversion-throws-exception.html

  • bindings/v8/custom/V8HTMLCollectionCustom.cpp: (WebCore::getItem):
Location:
trunk
Files:
2 added
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r76366 r76373  
     12011-01-21  Anton Muhin  <antonm@chromium.org>
     2
     3        Reviewed by Nate Chapin.
     4
     5        [v8] Properly deal with the case when conversion to string throws an exception for HTMLCollection accessors
     6        https://bugs.webkit.org/show_bug.cgi?id=52901
     7
     8        * fast/dom/htmlcollection-conversion-throws-exception-expected.txt: Added.
     9        * fast/dom/htmlcollection-conversion-throws-exception.html: Added.
     10
    1112011-01-21  Dimitri Glazkov  <dglazkov@chromium.org>
    212
  • trunk/Source/WebCore/ChangeLog

    r76372 r76373  
     12011-01-21  Anton Muhin  <antonm@chromium.org>
     2
     3        Reviewed by Nate Chapin.
     4
     5        [v8] Properly deal with the case when conversion to string throws an exception for HTMLCollection accessors
     6        https://bugs.webkit.org/show_bug.cgi?id=52901
     7
     8        Test: fast/dom/htmlcollection-conversion-throws-exception.html
     9
     10        * bindings/v8/custom/V8HTMLCollectionCustom.cpp:
     11        (WebCore::getItem):
     12
    1132011-01-21  Adam Roben  <aroben@apple.com>
    214
  • trunk/Source/WebCore/bindings/v8/custom/V8HTMLCollectionCustom.cpp

    r62791 r76373  
    6060    v8::Local<v8::Uint32> index = argument->ToArrayIndex();
    6161    if (index.IsEmpty()) {
    62         v8::Handle<v8::Value> result = getNamedItems(collection, toWebCoreString(argument->ToString()));
     62        v8::Local<v8::String> asString = argument->ToString();
     63        if (asString.IsEmpty())
     64            return v8::Handle<v8::Value>();
     65        v8::Handle<v8::Value> result = getNamedItems(collection, toWebCoreString(asString));
    6366
    6467        if (result.IsEmpty())
Note: See TracChangeset for help on using the changeset viewer.