简体   繁体   中英

IOS8 APP Crash, Application was working fine on iOS7

Crash starts when we kill the application and Again login to the application, App keep crashing at multiple views and screens.

Zombie warning sometimes says message was sent to deallocated space ie. [ object of View setImage:forState]. Sometmes *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*** -[__NSArrayM insertObject:atIndex:]: object cannot be nil' [ object of View setImage:forState]. Sometmes *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*** -[__NSArrayM insertObject:atIndex:]: object cannot be nil' , sometimes else and it's random.`

App worked fine on iOS7, issue only with iOS8

one of the Symbolicated Crash Logs :

Exception Type: EXC_CRASH (SIGABRT) Exception Codes: 0x0000000000000000, 0x0000000000000000 Triggered by Thread: 0

  Last Exception Backtrace: 0 CoreFoundation 0x2abe55f2 0x2aadd000 + 1082866 1 libobjc.A.dylib 0x3876fc72 0x38769000 + 27762 2 CoreFoundation 0x2aaf9152 0x2aadd000 + 115026 3 Service360 0x0018b162 -[CaseMgmtController tableView:cellForRowAtIndexPath:] (CaseMgmtController.m:1268) 4 UIKit 0x2e353128 0x2e07e000 + 2969896 5 UIKit 0x2e3531ea 0x2e07e000 + 2970090 6 UIKit 0x2e34890c 0x2e07e000 + 2926860 7 UIKit 0x2e160996 0x2e07e000 + 928150 8 UIKit 0x2e08a97a 0x2e07e000 + 51578 9 QuartzCore 0x2dab5f60 0x2daa9000 + 53088 10 QuartzCore 0x2dab194c 0x2daa9000 + 35148 11 QuartzCore 0x2dab17d4 0x2daa9000 + 34772 12 QuartzCore 0x2dab11c2 0x2daa9000 + 33218 13 QuartzCore 0x2dab0fcc 0x2daa9000 + 32716 14 QuartzCore 0x2daaaed8 0x2daa9000 + 7896 15 CoreFoundation 0x2abac010 0x2aadd000 + 847888 16 CoreFoundation 0x2aba96f4 0x2aadd000 + 837364 17 CoreFoundation 0x2aba9af6 0x2aadd000 + 838390 18 CoreFoundation 0x2aaf6b2c 0x2aadd000 + 105260 19 CoreFoundation 0x2aaf693e 0x2aadd000 + 104766 20 GraphicsServices 0x31ead04c 0x31ea4000 + 36940 21 UIKit 0x2e0ec6ec 0x2e07e000 + 452332 22 Service360 0x00096ffa main (main.m:18) 23 libdyld.dylib 0x38d0baaa 0x38d0a000 + 6826 
NSInteger index1, index2, index3;

index1= indexPath.row * MAX_NUMBER_OF_CELLS_IN_ONE_ROW;
index2=  index1 + 1;
index3=  index2 + 1;

static NSString *TableIdentifier = @"CellIdent";

UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:TableIdentifier];

UIView *Mainview = nil;

if (cell == nil) {
    cell = [[[UITableViewCell alloc] init]autorelease];
    NSArray *nib=[[NSBundle mainBundle]loadNibNamed:@"CaseManagementCell" owner:self options:nil];
    Mainview = (UIView *)[nib objectAtIndex:0]; 
    [cell addSubview:Mainview];
}

cell.backgroundColor = [UIColor clearColor];

Tried once more this time, i got this error below error message this time.

NSPathStore2 setImage:forState:]: unrecognized selector sent to instance 0x786bc950

When I tried printing the the hex I got :

po 0x786bc950 UITextFieldClearButton

*** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[NSPathStore2 setImage:forState:]: unrecognized selector sent to instance 0x786bc950'
*** First throw call stack:
(
    0   CoreFoundation                      0x031d8df6 __exceptionPreprocess + 182
    1   libobjc.A.dylib                     0x02cbca97 objc_exception_throw + 44
    2   CoreFoundation                      0x031e0a75 -[NSObject(NSObject) doesNotRecognizeSelector:] + 277
    3   CoreFoundation                      0x031299c7 ___forwarding___ + 1047
    4   CoreFoundation                      0x0312958e _CF_forwarding_prep_0 + 14
    5   UIKit                               0x01eead61 -[UITextField clearButton] + 312
    6   UIKit                               0x01eeaeaf -[UITextField _updateButtons] + 133
    7   UIKit                               0x01eed0e0 -[UITextField layoutSubviews] + 150
    8   UIKit                               0x017319c0 -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 608
    9   libobjc.A.dylib                     0x02cd2771 -[NSObject performSelector:withObject:] + 70
    10  QuartzCore                          0x0113a27f -[CALayer layoutSublayers] + 152
    11  QuartzCore                          0x0112e105 _ZN2CA5Layer16layout_if_neededEPNS_11TransactionE + 397
    12  QuartzCore                          0x0112df60 _ZN2CA5Layer28layout_and_display_if_neededEPNS_11TransactionE + 26
    13  QuartzCore                          0x0108c676 _ZN2CA7Context18commit_transactionEPNS_11TransactionE + 284
    14  QuartzCore                          0x0108da3c _ZN2CA11Transaction6commitEv + 392
    15  QuartzCore                          0x0108dc94 _ZN2CA11Transaction14release_threadEPv + 232
    16  libsystem_pthread.dylib             0x07aa981c _pthread_tsd_cleanup + 93
    17  libsystem_pthread.dylib             0x07aa627e _pthread_exit + 108
    18  libsystem_pthread.dylib             0x07aa61e8 pthread_exit + 33
    19  Foundation                          0x028e66c8 __NSFinalizeThreadData + 0
    20  Foundation                          0x028c2ac8 __NSThread__main__ + 1350
    21  libsystem_pthread.dylib             0x07aa55fb _pthread_body + 144
    22  libsystem_pthread.dylib             0x07aa5485 _pthread_struct_init + 0
    23  libsystem_pthread.dylib             0x07aaacf2 thread_start + 34
)
libc++abi.dylib: terminating with uncaught exception of type NSException

我遇到了同样的问题,只需将单元格的唯一标识符更改为Cell

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM