]> git.saurik.com Git - cycript.git/commitdiff
Found a memory management mistake (new Instance should not be transient) while workin...
authorJay Freeman (saurik) <saurik@saurik.com>
Fri, 2 Apr 2010 04:15:31 +0000 (04:15 +0000)
committerJay Freeman (saurik) <saurik@saurik.com>
Fri, 2 Apr 2010 04:15:31 +0000 (04:15 +0000)
ObjectiveC/Library.mm

index e8777b48a51571527404ca55fdb9f748bfd4a282..8776ca0ef465871357501311c0b2a708f6e5bc97 100644 (file)
@@ -2107,7 +2107,7 @@ static JSObjectRef Instance_new(JSContextRef context, JSObjectRef object, size_t
     if (count > 1)
         throw CYJSError(context, "incorrect number of arguments to Instance constructor");
     id self(count == 0 ? nil : CYCastPointer<id>(context, arguments[0]));
-    return Instance::Make(context, self);
+    return CYMakeInstance(context, self, false);
 } CYCatch }
 
 static JSValueRef CYValue_getProperty_value(JSContextRef context, JSObjectRef object, JSStringRef property, JSValueRef *exception) {