From 1cf12770640ddf1ea2e0656fec69d61b7389dc3c Mon Sep 17 00:00:00 2001 From: "Jay Freeman (saurik)" Date: Mon, 20 Jan 2014 04:43:32 -0800 Subject: [PATCH] Attempt to garbage collect before using choose(). --- ObjectiveC/Library.mm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ObjectiveC/Library.mm b/ObjectiveC/Library.mm index 742e3ef..a31c971 100644 --- a/ObjectiveC/Library.mm +++ b/ObjectiveC/Library.mm @@ -2305,6 +2305,8 @@ static JSValueRef choose(JSContextRef context, JSObjectRef object, JSObjectRef _ if (count != 1) throw CYJSError(context, "choose() takes a class argument"); + CYGarbageCollect(context); + CYPool pool; Class _class(CYCastNSObject(&pool, context, arguments[0])); -- 2.47.2