incubator-callback-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From shaz...@apache.org
Subject [2/7] ios commit: Don't use @autoreleasepool.
Date Mon, 09 Jul 2012 22:40:20 GMT
Don't use @autoreleasepool.

Doing so causes a runtime error in the 4.3 simulator.


Project: http://git-wip-us.apache.org/repos/asf/incubator-cordova-ios/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-cordova-ios/commit/f2d99398
Tree: http://git-wip-us.apache.org/repos/asf/incubator-cordova-ios/tree/f2d99398
Diff: http://git-wip-us.apache.org/repos/asf/incubator-cordova-ios/diff/f2d99398

Branch: refs/heads/master
Commit: f2d993980d0fa294b5e3fcf1a813e9d537f241cb
Parents: ce8938e
Author: Andrew Grieve <agrieve@chromium.org>
Authored: Fri Jul 6 09:56:36 2012 -0400
Committer: Shazron Abdullah <shazron@apache.org>
Committed: Mon Jul 9 14:31:35 2012 -0700

----------------------------------------------------------------------
 CordovaLib/CordovaLibApp/main.m |    7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-cordova-ios/blob/f2d99398/CordovaLib/CordovaLibApp/main.m
----------------------------------------------------------------------
diff --git a/CordovaLib/CordovaLibApp/main.m b/CordovaLib/CordovaLibApp/main.m
index e8a42e4..beae0aa 100644
--- a/CordovaLib/CordovaLibApp/main.m
+++ b/CordovaLib/CordovaLibApp/main.m
@@ -24,7 +24,8 @@
 
 int main(int argc, char *argv[])
 {
-    @autoreleasepool {
-        return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class]));
-    }
+    NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
+    int ret = UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class]));
+    [pool release];
+    return ret;
 }


Mime
View raw message