Ignore:
Timestamp:
Feb 19, 2008, 2:09:48 PM (17 years ago)
Author:
[email protected]
Message:

Reviewed by Darin.

Change OpaqueJSClass and RootObject to start with a ref count of 1.


  • API/JSClassRef.cpp: (OpaqueJSClass::OpaqueJSClass): (OpaqueJSClass::createNoAutomaticPrototype): (OpaqueJSClass::create):
  • API/JSClassRef.h:
  • API/JSObjectRef.cpp: (JSClassCreate):
  • bindings/runtime_root.cpp: (KJS::Bindings::RootObject::create): (KJS::Bindings::RootObject::RootObject):
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/API/JSObjectRef.cpp

    r30040 r30413  
    5050{
    5151    JSLock lock;
    52     JSClassRef jsClass = (definition->attributes & kJSClassAttributeNoAutomaticPrototype)
     52    RefPtr<OpaqueJSClass> jsClass = (definition->attributes & kJSClassAttributeNoAutomaticPrototype)
    5353        ? OpaqueJSClass::createNoAutomaticPrototype(definition)
    5454        : OpaqueJSClass::create(definition);
    5555   
    56     return JSClassRetain(jsClass);
     56    return jsClass.release().releaseRef();
    5757}
    5858
Note: See TracChangeset for help on using the changeset viewer.