Changeset 34160 in webkit for trunk/JavaScriptCore


Ignore:
Timestamp:
May 27, 2008, 5:44:40 PM (17 years ago)
Author:
[email protected]
Message:

JavaScriptCore:

2008-05-27 Anders Carlsson <[email protected]>

Reviewed by Geoff and Maciej.

<rdar://problem/5806428>
https://bugs.webkit.org/show_bug.cgi?id=17925
Crash in KJS::JSObject::put after setting this.proto

Set slotIsWriteable to false for proto, we want setting proto to go through JSObject::put instead.


  • kjs/object.h: (KJS::JSObject::getOwnPropertySlotForWrite):

LayoutTests:

2008-05-27 Anders Carlsson <[email protected]>

Reviewed by Geoff and Maciej.

<rdar://problem/5806428>
https://bugs.webkit.org/show_bug.cgi?id=17925
Crash in KJS::JSObject::put after setting this.proto

  • fast/js/resources/this-non-object-proto.js: Added.
  • fast/js/this-non-object-proto-expected.txt: Added.
  • fast/js/this-non-object-proto.html: Added.
Location:
trunk/JavaScriptCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/ChangeLog

    r34150 r34160  
     12008-05-27  Anders Carlsson  <[email protected]>
     2
     3        Reviewed by Geoff and Maciej.
     4
     5        <rdar://problem/5806428>
     6        https://bugs.webkit.org/show_bug.cgi?id=17925
     7        Crash in KJS::JSObject::put after setting this.__proto__
     8
     9        Set slotIsWriteable to false for __proto__, we want setting __proto__ to go through JSObject::put instead.
     10       
     11        * kjs/object.h:
     12        (KJS::JSObject::getOwnPropertySlotForWrite):
     13
    1142008-05-27  Kevin Ollivier  <[email protected]>
    215
  • trunk/JavaScriptCore/kjs/object.h

    r33979 r34160  
    597597    if (propertyName == exec->propertyNames().underscoreProto) {
    598598        slot.setValueSlot(this, &_proto);
    599         slotIsWriteable = true;
     599        slotIsWriteable = false;
    600600        return true;
    601601    }
Note: See TracChangeset for help on using the changeset viewer.