ARC 工程出现错误__NSAutoreleaseNoPool(): Object 0x8850ce0 of class __NSCFData autoreleased with no pool in
来源:互联网 发布:网络的利与弊初中作文 编辑:程序博客网 时间:2024/04/30 23:55
根据stackoverflow上面的大婶的回答:http://stackoverflow.com/questions/6475727/why-does-static-nsstring-leak
This message shows up when you autorelease an object on a thread that does not have any release pools in its stack. By default, there is always an autorelease pool on the main thread. It's created and managed within the UIApplicationMain()
function that is usually called by your app's main() function. However, additional threads you create (with performSelectorInBackground:
orNSThread
) do not have an autorelease pool in place unless you specifically put one there, so any autoreleased objects on that background thread have no pool to release them later, and will just leak.
If you're kicking something off to a background thread, the first thing you should do is create an autorelease pool. Under ARC, use the new @autoreleasepool
construct to do that.
- ARC 工程出现错误__NSAutoreleaseNoPool(): Object 0x8850ce0 of class __NSCFData autoreleased with no pool in
- *** __NSAutoreleaseNoPool(): Object 0x6013810 of class __NSArrayI autoreleased with no pool in place
- NSAutoReleaseNoPool(): Object 0x********* of class NSConreteData autoreleased with no pool in place
- nsthread autoreleased with no pool in place – just leaking警告的解决方法
- Unable to find a value for "Sex" in object of class ...错误
- 从svn下载工程出现"_OBJC_CLASS_$_", referenced from: objc-class-ref in MRAppDelegate.o错误
- 出现TypeError: Object #<Object> has no method 'createClient' 错误
- Android Studio出现 No service of type Factory available in ProjectScopeServices.的错误解决方案
- 生成圆角,使用curvycorners.js出现错误"No object with ID #calpopup exists yet"的解决
- 解决“no GUID has been associated with this object”错误
- mybatis中出现There is no getter for property named 'depIds' in 'class java.lang.String'的错误
- Method 'send' in the COM object of class 'Com.Message' returned error code 0x8004020F
- keil5 编译程序出现错误Error: L6411E: No compatible library exists with a definition of startup symbol __main
- keil5 编译程序出现错误Error: L6411E: No compatible library exists with a definition of startup symbol __main
- 解决错误Error creating bean with name 'MySessionFactory' defined in class path resource [applicationContext.xml]: Invocation of init
- cocoa编程错误问题:cannot decode object of class (XXX)
- 出现错误如下:AttributeError: 'module' object has no attribute 'SSL_ST_INIT'
- sencha touch中出现JS错误Uncaught TypeError: Object [object Object] has no method 'getForm'
- 如何让外网访问到IIS的web站点
- Android singleTop的应用
- 九度笔记之 1466:排列与二进制
- GSL Non-Complete Primer
- MyEclipse/Eclipse Color Themes
- ARC 工程出现错误__NSAutoreleaseNoPool(): Object 0x8850ce0 of class __NSCFData autoreleased with no pool in
- 社保那些事
- C:统计数组中不重复数组个数
- 把txt文本数据写入二维数组
- 启动weblogic时报错: java.lang.NoClassDefFoundError: weblogic/Server
- Ubuntu下,建立/复制/移动/删除文件或目录
- 汇编语言学习——第二章 寄存器(CPU工作原理)
- hl7 v2.X 版本中RSP_K23消息的构造
- UBOOT操作指令例子