Это приложение отлично работает на симуляторе iOS 7 без каких-либо проблем. Но когда я отлаживаю его на симуляторе iOS 8.1, он падает. Он даже не достигнет viewDidLoad контроллера 1-го вида.сбой приложений в iOS 8 при отладке, но работает, когда не отладка
Сразу после выхода компилятора applicaitondidFinishLaunchingWithOptions: сообщение об ошибке приложения.
Однако я могу запустить уже построенное приложение в iOS 8.1 симуляторе без каких-либо проблем. Сбой только тогда, когда я запускаю приложение через Xcode. Что может быть причиной? (учитывая тот факт, что он уже отлаживается в iOS 7)?
EDIT: (CRASH LOG)
UIKit`UIApplicationMain:
0x108ecff1e: pushq %rbp
0x108ecff1f: movq %rsp, %rbp
0x108ecff22: pushq %r15
0x108ecff24: pushq %r14
0x108ecff26: pushq %r13
0x108ecff28: pushq %r12
0x108ecff2a: pushq %rbx
0x108ecff2b: subq $0x38, %rsp
0x108ecff2f: movq %rcx, -0x48(%rbp)
0x108ecff33: movq %rdx, %r15
0x108ecff36: movq %rsi, %rbx
0x108ecff39: movl %edi, %r13d
0x108ecff3c: movq 0xb4ca8d(%rip), %rax ; (void *)0x000000010bcf1070: __stack_chk_guard
0x108ecff43: movq (%rax), %rax
0x108ecff46: movq %rax, -0x30(%rbp)
0x108ecff4a: leaq 0xdf66bb(%rip), %r14 ; _UIApplicationLinkedOnVersion
0x108ecff51: movl (%r14), %ecx
0x108ecff54: testl %ecx, %ecx
0x108ecff56: jne 0x108ecff7a ; UIApplicationMain + 92
0x108ecff58: xorl %eax, %eax
0x108ecff5a: cmpq $-0x1, 0xdf05ee(%rip) ; WebKitSetIsClassic + 7
0x108ecff62: je 0x108ecffa9 ; UIApplicationMain + 139
0x108ecff64: leaq 0xdf05e5(%rip), %rdi ; _UIApplicationLinkedOnVersionOnce
0x108ecff6b: leaq 0xb4fcfe(%rip), %rsi ; __block_literal_global1030
0x108ecff72: callq 0x1096a29e4 ; symbol stub for: dispatch_once
0x108ecff77: movl (%r14), %ecx
0x108ecff7a: xorl %eax, %eax
0x108ecff7c: cmpl $0x20100, %ecx
0x108ecff82: jb 0x108ecffa9 ; UIApplicationMain + 139
0x108ecff84: movq 0xdb8e15(%rip), %rdi ; (void *)0x000000010a4d7da8: NSAutoreleasePool
0x108ecff8b: movq 0xd8d406(%rip), %rsi ; "alloc"
0x108ecff92: movq 0xb4d0f7(%rip), %r14 ; (void *)0x000000010a881000: objc_msgSend
0x108ecff99: callq *%r14
0x108ecff9c: movq 0xd8d84d(%rip), %rsi ; "init"
0x108ecffa3: movq %rax, %rdi
0x108ecffa6: callq *%r14
0x108ecffa9: movq %r15, -0x50(%rbp)
0x108ecffad: movq %rax, -0x58(%rbp)
0x108ecffb1: cmpl $0x2, %r13d
0x108ecffb5: jl 0x108ed0019 ; UIApplicationMain + 251
0x108ecffb7: addq $0x8, %rbx
0x108ecffbb: decl %r13d
0x108ecffbe: leaq 0x8a9075(%rip), %r14 ; "-BuildDefaultPNG"
0x108ecffc5: leaq 0x8a907f(%rip), %r15 ; "-RegisterForSystemEvents"
0x108ecffcc: movq (%rbx), %r12
0x108ecffcf: movq %r12, %rdi
0x108ecffd2: movq %r14, %rsi
0x108ecffd5: callq 0x1096a2cd8 ; symbol stub for: strcmp
0x108ecffda: testl %eax, %eax
0x108ecffdc: je 0x108ed0009 ; UIApplicationMain + 235
0x108ecffde: movq %r12, %rdi
0x108ecffe1: movq %r15, %rsi
0x108ecffe4: callq 0x1096a2cd8 ; symbol stub for: strcmp
0x108ecffe9: testl %eax, %eax
0x108ecffeb: je 0x108ed0000 ; UIApplicationMain + 226
0x108ecffed: movq %r12, %rdi
0x108ecfff0: leaq 0x8a906d(%rip), %rsi ; "--RegisterForSystemEvents"
0x108ecfff7: callq 0x1096a2cd8 ; symbol stub for: strcmp
0x108ecfffc: testl %eax, %eax
0x108ecfffe: jne 0x108ed0010 ; UIApplicationMain + 242
0x108ed0000: movb $0x1, 0xdf656c(%rip) ; __ShouldLaunchSafe
0x108ed0007: jmp 0x108ed0010 ; UIApplicationMain + 242
0x108ed0009: movb $0x1, 0xdf6561(%rip) ; __IsRunningTests
0x108ed0010: addq $0x8, %rbx
0x108ed0014: decl %r13d
0x108ed0017: jne 0x108ecffcc ; UIApplicationMain + 174
0x108ed0019: xorl %eax, %eax
0x108ed001b: callq 0x1096a1592 ; symbol stub for: BKSDisplayServicesStart
0x108ed0020: callq 0x108ed0d0b ; UIApplicationInitialize
0x108ed0025: movq 0xdb8d24(%rip), %rdi ; (void *)0x0000000109c9ec80: UIApplication
0x108ed002c: movq 0xd8d39d(%rip), %rsi ; "class"
0x108ed0033: callq *0xb4d057(%rip) ; (void *)0x000000010a881000: objc_msgSend
0x108ed0039: movq %rax, %r15
0x108ed003c: movq -0x50(%rbp), %rbx
0x108ed0040: testq %rbx, %rbx
0x108ed0043: jne 0x108ed0081 ; UIApplicationMain + 355
0x108ed0045: movq 0xdb8d34(%rip), %rdi ; (void *)0x000000010a4d7e20: NSBundle
0x108ed004c: movq 0xd8e0dd(%rip), %rsi ; "mainBundle"
0x108ed0053: movq 0xb4d036(%rip), %r14 ; (void *)0x000000010a881000: objc_msgSend
0x108ed005a: callq *%r14
0x108ed005d: movq 0xd8e0d4(%rip), %rsi ; "infoDictionary"
0x108ed0064: movq %rax, %rdi
0x108ed0067: callq *%r14
0x108ed006a: movq 0xd8d38f(%rip), %rsi ; "objectForKey:"
0x108ed0071: leaq 0xb8b4b8(%rip), %rdx ; @"NSPrincipalClass"
0x108ed0078: movq %rax, %rdi
0x108ed007b: callq *%r14
0x108ed007e: movq %rax, %rbx
0x108ed0081: movq 0xd8e0c0(%rip), %rsi ; "length"
0x108ed0088: movq %rbx, %rdi
0x108ed008b: callq *0xb4cfff(%rip) ; (void *)0x000000010a881000: objc_msgSend
0x108ed0091: testq %rax, %rax
0x108ed0094: movq -0x48(%rbp), %r13
0x108ed0098: je 0x108ed0127 ; UIApplicationMain + 521
0x108ed009e: movq %rbx, %rdi
0x108ed00a1: callq 0x1096a19ca ; symbol stub for: NSClassFromString
0x108ed00a6: movq %rax, %r15
0x108ed00a9: testq %r15, %r15
0x108ed00ac: jne 0x108ed0127 ; UIApplicationMain + 521
0x108ed00ae: movq 0xdb8b33(%rip), %rdi ; (void *)0x000000010a4d8500: NSAssertionHandler
0x108ed00b5: movq 0xd8d47c(%rip), %rsi ; "currentHandler"
0x108ed00bc: movq 0xb4cfcd(%rip), %r12 ; (void *)0x000000010a881000: objc_msgSend
0x108ed00c3: callq *%r12
0x108ed00c6: movq %rax, -0x50(%rbp)
0x108ed00ca: movq 0xdb8b1f(%rip), %rdi ; (void *)0x000000010a4dae90: NSString
0x108ed00d1: movq 0xd8d468(%rip), %rsi ; "stringWithUTF8String:"
0x108ed00d8: leaq 0x8a8fb0(%rip), %rdx ; "int UIApplicationMain(int, char **, NSString *, NSString *)"
0x108ed00df: callq *%r12
0x108ed00e2: movq %rax, %r14
0x108ed00e5: movq 0xdb8b04(%rip), %rdi ; (void *)0x000000010a4dae90: NSString
0x108ed00ec: movq 0xd8d44d(%rip), %rsi ; "stringWithUTF8String:"
0x108ed00f3: leaq 0x8a868f(%rip), %rdx ; "/SourceCache/UIKit_Sim/UIKit-3318.16.14/UIApplication.m"
0x108ed00fa: callq *%r12
0x108ed00fd: movq %rax, %rcx
0x108ed0100: movq 0xd8e179(%rip), %rsi ; "handleFailureInFunction:file:lineNumber:description:"
0x108ed0107: movq %rbx, (%rsp)
0x108ed010b: leaq 0xb8b43e(%rip), %r9 ; @"Unable to instantiate the UIApplication subclass instance. No class named %@ is loaded."
0x108ed0112: xorl %r15d, %r15d
0x108ed0115: movl $0xb36, %r8d
0x108ed011b: xorl %eax, %eax
0x108ed011d: movq %r14, %rdx
0x108ed0120: movq -0x50(%rbp), %rdi
0x108ed0124: callq *%r12
0x108ed0127: leaq 0x330(%rip), %rdi ; _UIApplicationHandleEvent
0x108ed012e: callq 0x1096a1d12 ; symbol stub for: GSEventRegisterEventCallBack
0x108ed0133: leaq 0x8f1(%rip), %rdi ; _UIApplicationHandleHIDEvent
0x108ed013a: callq 0x1096a15bc ; symbol stub for: BKSHIDEventRegisterEventCallback
0x108ed013f: movq 0xd8d28a(%rip), %rsi ; "class"
0x108ed0146: movq 0xb4cf43(%rip), %r12 ; (void *)0x000000010a881000: objc_msgSend
0x108ed014d: movq %r15, %rdi
0x108ed0150: callq *%r12
0x108ed0153: movq 0xd8e196(%rip), %rsi ; "registerAsSystemApp"
0x108ed015a: movq %rax, %rdi
0x108ed015d: callq *%r12
0x108ed0160: movb %al, 0xdf640d(%rip) ; __RegisterAsSystemApp
0x108ed0166: cmpq $-0x1, 0xdf0372(%rip) ; __signalRunLoopSource + 7
0x108ed016e: jne 0x108ed0446 ; UIApplicationMain + 1320
0x108ed0174: cmpb $0x0, 0xdf036d(%rip) ; _UIApplicationIsExtension.once + 7
0x108ed017b: je 0x108ed0186 ; UIApplicationMain + 616
0x108ed017d: xorl %eax, %eax
0x108ed017f: callq 0x1096a1cee ; symbol stub for: GSEventInitializeAsExtension
0x108ed0184: jmp 0x108ed0192 ; UIApplicationMain + 628
0x108ed0186: movzbl 0xdf63e6(%rip), %edi ; __RegisterAsSystemApp
0x108ed018d: callq 0x1096a1ce8 ; symbol stub for: GSEventInitialize
0x108ed0192: movq 0xb4cca7(%rip), %rax ; (void *)0x000000010ae3f300: NSDefaultRunLoopMode
0x108ed0199: movq (%rax), %rdi
0x108ed019c: callq 0x1096a1d06 ; symbol stub for: GSEventPushRunLoopMode
0x108ed01a1: movq 0xd8e430(%rip), %rsi ; "_startWindowServerIfNecessary"
0x108ed01a8: movq %r15, %rdi
0x108ed01ab: callq *%r12
0x108ed01ae: movq 0xd8e42b(%rip), %rsi ; "_startStatusBarServerIfNecessary"
0x108ed01b5: movq %r15, %rdi
0x108ed01b8: callq *%r12
0x108ed01bb: movq %r15, %rdi
0x108ed01be: callq 0x108ecfdd0 ; UIApplicationInstantiateSingleton
0x108ed01c3: movq 0xdb8c56(%rip), %rdi ; (void *)0x000000010e867498: FBSUIApplicationSystemService
0x108ed01ca: movq 0xd8d1c7(%rip), %rsi ; "alloc"
0x108ed01d1: callq *%r12
0x108ed01d4: movq 0xd8e40d(%rip), %rsi ; "initWithQueue:"
0x108ed01db: movq 0xb4c7fe(%rip), %rdx ; (void *)0x000000010bbe4780: _dispatch_main_q
0x108ed01e2: movq %rax, %rdi
0x108ed01e5: callq *%r12
0x108ed01e8: movq %rax, 0xdf0319(%rip) ; __systemAppService
0x108ed01ef: movq 0xdf6372(%rip), %rdx ; UIApp
0x108ed01f6: movq 0xd8d48b(%rip), %rsi ; "setDelegate:"
0x108ed01fd: movq %rax, %rdi
0x108ed0200: callq *%r12
0x108ed0203: movq 0xdb8c1e(%rip), %rdi ; (void *)0x000000010e867650: FBSUIApplicationWorkspace
0x108ed020a: movq 0xd8d187(%rip), %rsi ; "alloc"
0x108ed0211: callq *%r12
0x108ed0214: movq %rax, %r14
0x108ed0217: movq 0xdb8c12(%rip), %rbx ; (void *)0x000000010e868168: FBSSerialQueue
0x108ed021e: movq 0xb4cc13(%rip), %rax ; (void *)0x000000010ae3f308: NSRunLoopCommonModes
0x108ed0225: movq (%rax), %rax
0x108ed0228: movq %rax, -0x40(%rbp)
0x108ed022c: leaq 0xb8d9dd(%rip), %rax ; @"UIInitializationRunLoopMode"
0x108ed0233: movq %rax, -0x38(%rbp)
0x108ed0237: movq 0xdb897a(%rip), %rdi ; (void *)0x000000010ae78cd8: NSArray
0x108ed023e: movq 0xd8d0fb(%rip), %rsi ; "arrayWithObjects:count:"
0x108ed0245: leaq -0x40(%rbp), %rdx
0x108ed0249: movl $0x2, %ecx
0x108ed024e: callq *%r12
0x108ed0251: movq 0xd8e398(%rip), %rsi ; "queueWithMainRunLoopModes:"
0x108ed0258: movq %rbx, %rdi
0x108ed025b: movq %rax, %rdx
0x108ed025e: callq *%r12
0x108ed0261: movq 0xd8e390(%rip), %rsi ; "initWithSerialQueue:"
0x108ed0268: movq %r14, %rdi
0x108ed026b: movq %rax, %rdx
0x108ed026e: callq *%r12
0x108ed0271: movq %rax, 0xdf0238(%rip) ; __workspace
0x108ed0278: movq 0xdf62e9(%rip), %rdx ; UIApp
0x108ed027f: movq 0xd8d402(%rip), %rsi ; "setDelegate:"
0x108ed0286: movq %rax, %rdi
0x108ed0289: callq *%r12
0x108ed028c: movq 0xdb8965(%rip), %rdi ; (void *)0x0000000109ca4540: UIDevice
0x108ed0293: movq 0xd8d2d6(%rip), %rsi ; "currentDevice"
0x108ed029a: callq *%r12
0x108ed029d: movq 0xd8d2d4(%rip), %rsi ; "userInterfaceIdiom"
0x108ed02a4: movq %rax, %rdi
0x108ed02a7: callq *%r12
0x108ed02aa: cmpq $0x1, %rax
0x108ed02ae: jne 0x108ed02c4 ; UIApplicationMain + 934
0x108ed02b0: movq 0xdb8af1(%rip), %rdi ; (void *)0x0000000109cab250: UIClassicController
0x108ed02b7: movq 0xd8e062(%rip), %rsi ; "sharedClassicController"
0x108ed02be: callq *0xb4cdcc(%rip) ; (void *)0x000000010a881000: objc_msgSend
0x108ed02c4: testq %r13, %r13
0x108ed02c7: jne 0x108ed0307 ; UIApplicationMain + 1001
0x108ed02c9: movq 0xdb8ab0(%rip), %rdi ; (void *)0x000000010a4d7e20: NSBundle
0x108ed02d0: movq 0xd8de59(%rip), %rsi ; "mainBundle"
0x108ed02d7: callq *%r12
0x108ed02da: movq 0xd8de57(%rip), %rsi ; "infoDictionary"
0x108ed02e1: movq %rax, %rdi
0x108ed02e4: callq *%r12
0x108ed02e7: movq 0xd8d112(%rip), %rsi ; "objectForKey:"
0x108ed02ee: leaq 0xb8b27b(%rip), %rdx ; @"UIApplicationDelegateClass"
0x108ed02f5: movq %rax, %rdi
0x108ed02f8: callq *%r12
0x108ed02fb: movq %rax, %r13
0x108ed02fe: testq %r13, %r13
0x108ed0301: je 0x108ed0401 ; UIApplicationMain + 1251
0x108ed0307: movq %r13, %rdi
0x108ed030a: callq 0x1096a19ca ; symbol stub for: NSClassFromString
0x108ed030f: movq %rax, %r14
0x108ed0312: testq %r14, %r14
0x108ed0315: jne 0x108ed0384 ; UIApplicationMain + 1126
0x108ed0317: movq 0xdb88ca(%rip), %rdi ; (void *)0x000000010a4d8500: NSAssertionHandler
0x108ed031e: movq 0xd8d213(%rip), %rsi ; "currentHandler"
0x108ed0325: callq *%r12
0x108ed0328: movq %rax, %r15
0x108ed032b: movq 0xdb88be(%rip), %rdi ; (void *)0x000000010a4dae90: NSString
0x108ed0332: movq 0xd8d207(%rip), %rsi ; "stringWithUTF8String:"
0x108ed0339: leaq 0x8a8d4f(%rip), %rdx ; "int UIApplicationMain(int, char **, NSString *, NSString *)"
0x108ed0340: callq *%r12
0x108ed0343: movq %rax, %rbx
0x108ed0346: movq 0xdb88a3(%rip), %rdi ; (void *)0x000000010a4dae90: NSString
0x108ed034d: movq 0xd8d1ec(%rip), %rsi ; "stringWithUTF8String:"
0x108ed0354: leaq 0x8a842e(%rip), %rdx ; "/SourceCache/UIKit_Sim/UIKit-3318.16.14/UIApplication.m"
0x108ed035b: callq *%r12
0x108ed035e: movq %rax, %rcx
0x108ed0361: movq 0xd8df18(%rip), %rsi ; "handleFailureInFunction:file:lineNumber:description:"
0x108ed0368: movq %r13, (%rsp)
0x108ed036c: leaq 0xb8b21d(%rip), %r9 ; @"Unable to instantiate the UIApplication delegate instance. No class named %@ is loaded."
0x108ed0373: movl $0xb62, %r8d
0x108ed0379: xorl %eax, %eax
0x108ed037b: movq %rbx, %rdx
0x108ed037e: movq %r15, %rdi
0x108ed0381: callq *%r12
0x108ed0384: movq 0xdb89c5(%rip), %rdi ; (void *)0x0000000109c9ec80: UIApplication
0x108ed038b: movq 0xd8d03e(%rip), %rsi ; "class"
0x108ed0392: callq *%r12
0x108ed0395: movq 0xd8e264(%rip), %rsi ; "isSubclassOfClass:"
0x108ed039c: movq %r14, %rdi
0x108ed039f: movq %rax, %rdx
0x108ed03a2: callq *%r12
0x108ed03a5: movq 0xdf61bc(%rip), %rbx ; UIApp
0x108ed03ac: testb %al, %al
0x108ed03ae: je 0x108ed03c5 ; UIApplicationMain + 1191
0x108ed03b0: movq 0xd8d2d1(%rip), %rsi ; "setDelegate:"
0x108ed03b7: movq %rbx, %rdi
0x108ed03ba: movq %rbx, %rdx
0x108ed03bd: callq *0xb4cccd(%rip) ; (void *)0x000000010a881000: objc_msgSend
0x108ed03c3: jmp 0x108ed0401 ; UIApplicationMain + 1251
0x108ed03c5: movq 0xd8cfcc(%rip), %rsi ; "alloc"
0x108ed03cc: movq %r14, %rdi
0x108ed03cf: callq *%r12
0x108ed03d2: movq 0xd8d417(%rip), %rsi ; "init"
0x108ed03d9: movq %rax, %rdi
0x108ed03dc: callq *%r12
0x108ed03df: movq 0xd8d4d2(%rip), %rsi ; "autorelease"
0x108ed03e6: movq %rax, %rdi
0x108ed03e9: callq *%r12
0x108ed03ec: movq 0xd8e215(%rip), %rsi ; "_setDelegate:assumeOwnership:"
0x108ed03f3: movl $0x1, %ecx
0x108ed03f8: movq %rbx, %rdi
0x108ed03fb: movq %rax, %rdx
0x108ed03fe: callq *%r12
0x108ed0401: movq 0xd8cf78(%rip), %rsi ; "release"
0x108ed0408: movq -0x58(%rbp), %rdi
0x108ed040c: callq *%r12
0x108ed040f: movq 0xdf6152(%rip), %rdi ; UIApp
0x108ed0416: movq 0xd8e1f3(%rip), %rsi ; "_run"
0x108ed041d: callq *%r12
0x108ed0420: movq 0xb4c5a9(%rip), %rax ; (void *)0x000000010bcf1070: __stack_chk_guard
0x108ed0427: movq (%rax), %rax
0x108ed042a: cmpq -0x30(%rbp), %rax
0x108ed042e: jne 0x108ed0441 ; UIApplicationMain + 1315
0x108ed0430: xorl %eax, %eax
0x108ed0432: addq $0x38, %rsp
0x108ed0436: popq %rbx
0x108ed0437: popq %r12
0x108ed0439: popq %r13
0x108ed043b: popq %r14
0x108ed043d: popq %r15
0x108ed043f: popq %rbp
0x108ed0440: retq
0x108ed0441: callq 0x1096a2936 ; symbol stub for: __stack_chk_fail
0x108ed0446: leaq 0xdf0093(%rip), %rdi ; _UIApplicationIsExtension.once
0x108ed044d: leaq 0xb4f57c(%rip), %rsi ; __block_literal_global616
0x108ed0454: callq 0x1096a29e4 ; symbol stub for: dispatch_once
0x108ed0459: jmp 0x108ed0174 ; UIApplicationMain + 598
точка останова останавливается рядом:
0x108ed0420: movq 0xb4c5a9(%rip), %rax ; (void *)0x000000010bcf1070: __stack_chk_guard
Вы получаете crashlog или еще что-то? Попробуйте включить зомби и установите точку останова «Все исключения» –
@HermannKlecker Я включил все исключения, но все же попал в основной метод UIApplicationMain при сбое. Однако я вижу эту строку в области отладки: argc: (int) argc = 1 argv: (char **) argv = 0x00007fff5740d4e8 – sleepwalkerfx
Посмотрите на это 'Не удалось создать экземпляр делегата UIApplication. Ни один класс с именем% @ не загружен. По-видимому, он не может инициализировать AppDelegate. Можете ли вы показать свой метод 'main' в файле' main.m'? –