开发者

Strange error using Core Data

开发者 https://www.devze.com 2023-03-04 08:38 出处:网络
I have a problem with Core Data in my application. There is no certain situation when my app crashes. It is very random. At the time of this crash I\'m adding and modifying objects and saving NSManage

I have a problem with Core Data in my application. There is no certain situation when my app crashes. It is very random. At the time of this crash I'm adding and modifying objects and saving NSManageObjectContext. Does anyone know what could be the problem?

#0  0x32668ebc in objc_msgSend
#1  0x30494300 in -[NSKnownKeysDictionary1 dealloc]
#2  0x3049429c in -[NSKnownKeysDictionary1 release]
#3  0x304c76d2 in -[NSManagedObje开发者_高级运维ct(_NSInternalMethods) _nilOutReservedCurrentEventSnapshot__]
#4  0x3049c31a in -[NSManagedObjectContext(_NSInternalChangeProcessing) _processRecentChanges:]
#5  0x304d1bec in -[NSManagedObjectContext processPendingChanges]
#6  0x304c4380 in _performRunLoopAction
#7  0x32d5c830 in __CFRunLoopDoObservers
#8  0x32da4346 in CFRunLoopRunSpecific
#9  0x32da3c1e in CFRunLoopRunInMode
#10 0x31bb9374 in GSEventRunModal
#11 0x30bf3c30 in -[UIApplication _run]
#12 0x30bf2230 in UIApplicationMain
#13 0x0000e9a2 in main at main.m:59


This definitely looks like an over released object. Try setting the NSZombieEnabled environment variable to YES before running the app to get a better pin-pointed crash to where the object is actually over released.

Here is a short and sweet blog-post describing zombies and crashes: http://cocoa-nut.de/?p=16

0

精彩评论

暂无评论...
验证码 换一张
取 消