Changeset 53285 in webkit


Ignore:
Timestamp:
Jan 14, 2010 12:13:28 PM (14 years ago)
Author:
eric@webkit.org
Message:

2010-01-14 Kent Hansen <kent.hansen@nokia.com>

Reviewed by Darin Adler.

Infinite recursion in RuntimeObjectImp::getOwnPropertyNames()
https://bugs.webkit.org/show_bug.cgi?id=33371

Test that Object.keys works on a plugin object.

  • plugins/netscape-enumerate.html:

2010-01-14 Kent Hansen <kent.hansen@nokia.com>

Reviewed by Darin Adler.

Infinite recursion in RuntimeObjectImp::getOwnPropertyNames()
https://bugs.webkit.org/show_bug.cgi?id=33371

RuntimeObjectImp should not reimplement getPropertyNames();
move the implementation to getOwnPropertyNames().

  • bridge/runtime_object.cpp: (JSC::RuntimeObjectImp::getOwnPropertyNames):
  • bridge/runtime_object.h:
Location:
trunk
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r53283 r53285  
     12010-01-14  Kent Hansen  <kent.hansen@nokia.com>
     2
     3        Reviewed by Darin Adler.
     4
     5        Infinite recursion in RuntimeObjectImp::getOwnPropertyNames()
     6        https://bugs.webkit.org/show_bug.cgi?id=33371
     7
     8        Test that Object.keys works on a plugin object.
     9
     10        * plugins/netscape-enumerate.html:
     11
    1122010-01-14  Adam Roben  <aroben@apple.com>
    213
  • trunk/LayoutTests/plugins/netscape-enumerate.html

    r20613 r53285  
    3030    }
    3131
     32    // Now try enumerating a plugin object's properties using Object.keys
     33    var keys = Object.keys(plugin.testObject);
     34    if (keys.toString() != 'foo,bar') {
     35        result.innerHTML = 'FAILURE: Plugin object properties returned by Object.keys were ' + keys.toString();
     36        return;
     37    }
     38
    3239    result.innerHTML = 'SUCCESS';
    3340}
  • trunk/WebCore/ChangeLog

    r53284 r53285  
     12010-01-14  Kent Hansen  <kent.hansen@nokia.com>
     2
     3        Reviewed by Darin Adler.
     4
     5        Infinite recursion in RuntimeObjectImp::getOwnPropertyNames()
     6        https://bugs.webkit.org/show_bug.cgi?id=33371
     7
     8        RuntimeObjectImp should not reimplement getPropertyNames();
     9        move the implementation to getOwnPropertyNames().
     10
     11        * bridge/runtime_object.cpp:
     12        (JSC::RuntimeObjectImp::getOwnPropertyNames):
     13        * bridge/runtime_object.h:
     14
    1152010-01-14  Kwang Yul Seo  <skyul@company100.net>
    216
  • trunk/WebCore/bridge/runtime_object.cpp

    r53170 r53285  
    303303}
    304304
    305 void RuntimeObjectImp::getPropertyNames(ExecState* exec, PropertyNameArray& propertyNames, EnumerationMode)
     305void RuntimeObjectImp::getOwnPropertyNames(ExecState* exec, PropertyNameArray& propertyNames, EnumerationMode)
    306306{
    307307    if (!m_instance) {
     
    317317}
    318318
    319 void RuntimeObjectImp::getOwnPropertyNames(ExecState* exec, PropertyNameArray& propertyNames, EnumerationMode mode)
    320 {
    321     getOwnPropertyNames(exec, propertyNames, mode);
    322 }
    323 
    324319JSObject* RuntimeObjectImp::throwInvalidAccessError(ExecState* exec)
    325320{
  • trunk/WebCore/bridge/runtime_object.h

    r53170 r53285  
    4545    virtual ConstructType getConstructData(ConstructData&);
    4646
    47     virtual void getPropertyNames(ExecState*, PropertyNameArray&, EnumerationMode mode = ExcludeDontEnumProperties);
    4847    virtual void getOwnPropertyNames(ExecState*, PropertyNameArray&, EnumerationMode mode = ExcludeDontEnumProperties);
    4948
Note: See TracChangeset for help on using the changeset viewer.