Xcode crashes when I set a breakpoint in a completion callback - ios

I get Xcode quit unexpectedly while using the SimplePlayer plug-in.
simpleplayer is the name of the app.
Xcode 6.2 only happens in simulator. IOS target 8.1 and above. App works normal without breakpoint.
This only happens when I set the breakpoint in the completion callback.
Time Awake Since Boot: 530 seconds
Crashed Thread: 21 <lldb.process.internal-state(pid=1263)>
Exception Type: EXC_BAD_ACCESS (Code Signature Invalid)
Exception Codes: 0x0000000000000032, 0x000000014057b3bc
kernel messages:
-1 sec CODE SIGNING: cs_invalid_page(0x14057b000): p=1151[Xcode] final status 0x3004200, denying page sending SIGKILL
-1 sec CODE SIGNING: process 1151[Xcode]: rejecting invalid page at address 0x14057b000 from offset 0x225000 in file "/Users/USER/Library/Developer/CoreSimulator/Devices/C7E8D457-BFAB-43DA-8B0C-D9010BBB1D88/data/Containers/Bundle/Application/77AB1811-69B6-4079-B874-8E20A7160283/SimplePlayer.app/SimplePlayer" (cs_mtime:1427477037.0 == mtime:1427477037.0) (signed:1 validated:1 tainted:1 wpmapped:0 slid:0)
Thread 21 Crashed:: <lldb.process.internal-state(pid=1263)>
0 com.apple.LLDB.framework 0x000000010f2961f4 lldb_private::DataExtractor::GetU32_unchecked(unsigned long long*) const + 14
1 com.apple.LLDB.framework 0x000000010f39af99 ObjectFileMachO::ParseSymtab() + 3603
2 com.apple.LLDB.framework 0x000000010f39a0f2 ObjectFileMachO::GetSymtab() + 158
3 com.apple.LLDB.framework 0x000000010f43f238 lldb_private::SymbolVendor::GetSymtab() + 64
4 com.apple.LLDB.framework 0x000000010f2da04f lldb_private::Module::ResolveSymbolContextForAddress(lldb_private::Address const&, unsigned int, lldb_private::SymbolContext&, bool) + 333
5 com.apple.LLDB.framework 0x000000010f287295 lldb_private::Address::CalculateSymbolContext(lldb_private::SymbolContext*, unsigned int) const + 157
6 com.apple.LLDB.framework 0x000000010f42dede lldb_private::CompileUnit::ResolveSymbolContext(lldb_private::FileSpec const&, unsigned int, bool, bool, unsigned int, lldb_private::SymbolContextList&) + 630
7 com.apple.LLDB.framework 0x000000010f23b32b lldb_private::BreakpointResolverFileLine::SearchCallback(lldb_private::SearchFilter&, lldb_private::SymbolContext&, lldb_private::Address*, bool) + 217
8 com.apple.LLDB.framework 0x000000010f2efc8b lldb_private::SearchFilter::DoModuleIteration(lldb_private::SymbolContext const&, lldb_private::Searcher&) + 129
9 com.apple.LLDB.framework 0x000000010f2f00dc lldb_private::SearchFilter::DoModuleIteration(std::__1::shared_ptr<lldb_private::Module> const&, lldb_private::Searcher&) + 86
10 com.apple.LLDB.framework 0x000000010f2effc7 lldb_private::SearchFilter::SearchInModuleList(lldb_private::Searcher&, lldb_private::ModuleList&) + 241
11 com.apple.LLDB.framework 0x000000010f23339e lldb_private::Breakpoint::ModulesChanged(lldb_private::ModuleList&, bool, bool) + 772
12 com.apple.LLDB.framework 0x000000010f235955 lldb_private::BreakpointList::UpdateBreakpoints(lldb_private::ModuleList&, bool, bool) + 77
13 com.apple.LLDB.framework 0x000000010f4798ab lldb_private::Target::ModulesDidLoad(lldb_private::ModuleList&) + 69
14 com.apple.LLDB.framework 0x000000010f4797d6 lldb_private::Target::ModuleAdded(lldb_private::ModuleList const&, std::__1::shared_ptr<lldb_private::Module> const&) + 444
15 com.apple.LLDB.framework 0x000000010f2ddfad lldb_private::ModuleList::AppendImpl(std::__1::shared_ptr<lldb_private::Module> const&, bool) + 135
16 com.apple.LLDB.framework 0x000000010f47909c lldb_private::Target::GetSharedModule(lldb_private::ModuleSpec const&, lldb_private::Error*) + 1576
17 com.apple.LLDB.framework 0x000000010f3883b3 DynamicLoaderMacOSXDYLD::FindTargetModuleForDYLDImageInfo(DynamicLoaderMacOSXDYLD::DYLDImageInfo&, bool, bool*) + 331
18 com.apple.LLDB.framework 0x000000010f38a28c DynamicLoaderMacOSXDYLD::UpdateImageInfosHeaderAndLoadCommands(std::__1::vector<DynamicLoaderMacOSXDYLD::DYLDImageInfo, std::__1::allocator<DynamicLoaderMacOSXDYLD::DYLDImageInfo> >&, unsigned int, bool) + 256
19 com.apple.LLDB.framework 0x000000010f3898e5 DynamicLoaderMacOSXDYLD::AddModulesUsingImageInfosAddress(unsigned long long, unsigned int) + 153
20 com.apple.LLDB.framework 0x000000010f389744 DynamicLoaderMacOSXDYLD::NotifyBreakpointHit(void*, lldb_private::StoppointCallbackContext*, unsigned long long, unsigned long long) + 528
21 com.apple.LLDB.framework 0x000000010f23a146 lldb_private::BreakpointOptions::InvokeCallback(lldb_private::StoppointCallbackContext*, unsigned long long, unsigned long long) + 48
22 com.apple.LLDB.framework 0x000000010f237462 lldb_private::BreakpointLocation::InvokeCallback(lldb_private::StoppointCallbackContext*) + 82
23 com.apple.LLDB.framework 0x000000010f237bc5 lldb_private::BreakpointLocation::ShouldStop(lldb_private::StoppointCallbackContext*) + 115
24 com.apple.LLDB.framework 0x000000010f238816 lldb_private::BreakpointLocationCollection::ShouldStop(lldb_private::StoppointCallbackContext*) + 76
25 com.apple.LLDB.framework 0x000000010f240a74 lldb_private::BreakpointSite::ShouldStop(lldb_private::StoppointCallbackContext*) + 48
26 com.apple.LLDB.framework 0x000000010f4739e4 lldb_private::StopInfoBreakpoint::ShouldStopSynchronous(lldb_private::Event*) + 232
27 com.apple.LLDB.framework 0x000000010f487a1c lldb_private::Thread::ShouldStop(lldb_private::Event*) + 650
28 com.apple.LLDB.framework 0x000000010f48d285 lldb_private::ThreadList::ShouldStop(lldb_private::Event*) + 483
29 com.apple.LLDB.framework 0x000000010f46286d lldb_private::Process::ShouldBroadcastEvent(lldb_private::Event*) + 379
30 com.apple.LLDB.framework 0x000000010f46065e lldb_private::Process::HandlePrivateEvent(std::__1::shared_ptr<lldb_private::Event>&) + 356
31 com.apple.LLDB.framework 0x000000010f46305b lldb_private::Process::RunPrivateStateThread() + 511
32 com.apple.LLDB.framework 0x000000010f462a61 lldb_private::Process::PrivateStateThread(void*) + 9
33 libsystem_pthread.dylib 0x00007fff8cedc268 _pthread_body + 131
34 libsystem_pthread.dylib 0x00007fff8cedc1e5 _pthread_start + 176
35 libsystem_pthread.dylib 0x00007fff8ceda41d thread_start + 13

Related

When will trigger 'Pointer authentication' crash?

I get a crash by firebase. Only a useful information:
Corrupt NSInvocation detected. Pointer authentication.
I didn't met this type of crash before. And I found this error is related to PAC, which means Pointer Authentication. And PAC is enabled from A12 clip. Thus all devices had this crash were from iPhone XR / 11 / 12 / 13 and so on.
Below is the crash file:
2022-02-07_16-44-57.4063_+0700-4c0b14a2bc46de636f18885059d3ef71e86671cd.crash
Incident Identifier: 3A24760C-2DD9-417C-AD49-DE29CD5DC9FF
Hardware Model: iPhone11,6
Process: ShopeeFood [27579]
Path: /private/var/containers/Bundle/Application/153DB199-A6C5-4237-A7C2-B2AB7F54D97B/ShopeeFood.app/ShopeeFood
Identifier: vn.foody.DeliveryNow
Version: 5.11.1 (24)
AppStoreTools: 13C90b
AppVariant: 1:iPhone11,6:15
Code Type: ARM-64 (Native)
Role: Foreground
Parent Process: launchd [1]
Coalition: vn.foody.DeliveryNow [3660]
Date/Time: 2022-02-07 16:44:57.4063 +0700
Launch Time: 2022-02-07 15:21:52.7331 +0700
OS Version: iPhone OS 15.2.1 (19C63)
Release Type: User
Baseband Version: 4.02.02
Report Version: 104
Exception Type: EXC_BREAKPOINT (SIGTRAP)
Exception Codes: 0x0000000000000001, 0x0000000180a17f64
Exception Note: EXC_CORPSE_NOTIFY
Termination Reason: SIGNAL 5 Trace/BPT trap: 5
Terminating Process: exc handler [27579]
Triggered by Thread: 0
Kernel Triage:
VM - pmap_enter failed with resource shortage
VM - pmap_enter failed with resource shortage
Thread 0 name:
Thread 0 Crashed:
0 CoreFoundation 0x0000000180a17f64 _NSIPoisoned + 16 (NSForwarding.m:3059)
1 CoreFoundation 0x000000018094a1e8 -[NSInvocation setArgument:atIndex:] + 596 (NSForwarding.m:3068)
2 CoreFoundation 0x000000018091e9c4 -[NSInvocation invokeWithTarget:] + 64 (NSForwarding.m:3474)
3 React 0x000000010744b8dc -[RCTModuleMethod invokeWithBridge:module:arguments:] + 460 (RCTModuleMethod.mm:584)
4 React 0x000000010744da2c facebook::react::invokeInner(RCTBridge*, RCTModuleData*, unsigned int, folly::dynamic const&) + 244 (RCTNativeModule.mm:114)
5 React 0x000000010744d790 facebook::react::RCTNativeModule::invoke(unsigned int, folly::dynamic&&, int)::$_0::operator()() const + 44 (RCTNativeModule.mm:75)
6 React 0x000000010744d790 ___ZN8facebook5react15RCTNativeModule6invokeEjON5folly7dynamicEi_block_invoke + 88 (RCTNativeModule.mm:67)
7 React 0x000000010744d5f0 facebook::react::RCTNativeModule::invoke(unsigned int, folly::dynamic&&, int) + 388 (RCTNativeModule.mm:80)
8 cxxreact 0x0000000108932e70 facebook::react::JsToNativeBridge::callNativeModules(facebook::react::JSExecutor&, folly::dynamic&&, bool) + 152 (NativeToJsBridge.cpp:62)
9 jsireact 0x0000000108acf1dc facebook::react::JSIExecutor::callNativeModules(facebook::jsi::Value const&, bool) + 92 (JSIExecutor.cpp:388)
10 jsireact 0x0000000108ad132c facebook::react::JSIExecutor::initializeRuntime()::$_1::operator()(facebook::jsi::Runtime&, facebook::jsi::Value const&, facebook::jsi::Value const*, unsigned long) const + 8 (JSIExecutor.cpp:104)
11 jsireact 0x0000000108ad132c decltype(std::__1::forward<facebook::react::JSIExecutor::initializeRuntime()::$_1&>(fp)(std::__1::forward<facebook::jsi::Runtime&>(fp0), std::__1::forward<facebook::jsi::Value const&>(fp0), std::__... + 28 (type_traits:3747)
12 jsireact 0x0000000108ad132c facebook::jsi::Value std::__1::__invoke_void_return_wrapper<facebook::jsi::Value>::__call<facebook::react::JSIExecutor::initializeRuntime()::$_1&, facebook::jsi::Runtime&, facebook::jsi::Value cons... + 28 (__functional_base:317)
13 jsireact 0x0000000108ad132c std::__1::__function::__alloc_func<facebook::react::JSIExecutor::initializeRuntime()::$_1, std::__1::allocator<facebook::react::JSIExecutor::initializeRuntime()::$_1>, facebook::jsi::Value (faceboo... + 28 (functional:1553)
14 jsireact 0x0000000108ad132c std::__1::__function::__func<facebook::react::JSIExecutor::initializeRuntime()::$_1, std::__1::allocator<facebook::react::JSIExecutor::initializeRuntime()::$_1>, facebook::jsi::Value (facebook::jsi... + 44 (functional:1727)
15 jsi 0x0000000108a7d804 std::__1::__function::__value_func<facebook::jsi::Value (facebook::jsi::Runtime&, facebook::jsi::Value const&, facebook::jsi::Value const*, unsigned long)>::operator()(facebook::jsi::Runtime&, face... + 28 (functional:1880)
16 jsi 0x0000000108a7d804 std::__1::function<facebook::jsi::Value (facebook::jsi::Runtime&, facebook::jsi::Value const&, facebook::jsi::Value const*, unsigned long)>::operator()(facebook::jsi::Runtime&, facebook::jsi::Value... + 44 (functional:2555)
17 jsi 0x0000000108a7d548 facebook::jsc::JSCRuntime::createFunctionFromHostFunction(facebook::jsi::PropNameID const&, unsigned int, std::__1::function<facebook::jsi::Value (facebook::jsi::Runtime&, facebook::jsi::Value cons... + 384 (JSCRuntime.cpp:1151)
18 JavaScriptCore 0x000000018bc2352c JSC::JSCallbackObject<JSC::JSNonFinalObject>::callImpl(JSC::JSGlobalObject*, JSC::CallFrame*) + 468 (JSCallbackObjectFunctions.h:566)
19 JavaScriptCore 0x000000018c3f13c4 JSC::LLInt::setUpCall(JSC::CallFrame*, JSC::CodeSpecializationKind, JSC::JSValue, JSC::LLIntCallLinkInfo*) + 1736 (NativeFunction.h:50)
20 JavaScriptCore 0x000000018bb7b7b0 llint_function_for_construct_arity_checkTagGateAfter + 144508
21 JavaScriptCore 0x000000018bb7b70c llint_function_for_construct_arity_checkTagGateAfter + 144344
22 JavaScriptCore 0x000000018bb7b7e0 llint_function_for_construct_arity_checkTagGateAfter + 144556
23 JavaScriptCore 0x000000018bb7b70c llint_function_for_construct_arity_checkTagGateAfter + 144344
24 JavaScriptCore 0x000000018bb7ba70 llint_function_for_construct_arity_checkTagGateAfter + 145212
25 JavaScriptCore 0x000000018bb52028 vmEntryToJavaScriptTrampoline + 8
26 JavaScriptCore 0x000000018c28c704 JSC::Interpreter::executeProgram(JSC::SourceCode const&, JSC::JSGlobalObject*, JSC::JSObject*) + 12632 (JITCodeInlines.h:42)
27 JavaScriptCore 0x000000018c568c28 JSC::evaluate(JSC::JSGlobalObject*, JSC::SourceCode const&, JSC::JSValue, ***::NakedPtr<JSC::Exception>&) + 272 (Completion.cpp:137)
28 JavaScriptCore 0x000000018bc19ae8 JSEvaluateScript + 724 (JSBase.cpp:53)
29 jsi 0x0000000108a78b08 facebook::jsc::JSCRuntime::evaluateJavaScript(std::__1::shared_ptr<facebook::jsi::Buffer const> const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&) + 292 (JSCRuntime.cpp:426)
30 jsireact 0x0000000108ace460 facebook::react::JSIExecutor::loadBundle(std::__1::unique_ptr<facebook::react::JSBigString const, std::__1::default_delete<facebook::react::JSBigString const> >, std::__1::basic_string<char, std::_... + 328 (JSIExecutor.cpp:158)
31 cxxreact 0x0000000108932310 facebook::react::NativeToJsBridge::loadBundleSync(std::__1::unique_ptr<facebook::react::RAMBundleRegistry, std::__1::default_delete<facebook::react::RAMBundleRegistry> >, std::__1::unique_ptr<faceb... + 152 (NativeToJsBridge.cpp:154)
32 cxxreact 0x0000000108925a4c facebook::react::Instance::loadBundleSync(std::__1::unique_ptr<facebook::react::RAMBundleRegistry, std::__1::default_delete<facebook::react::RAMBundleRegistry> >, std::__1::unique_ptr<facebook::rea... + 164 (Instance.cpp:88)
33 cxxreact 0x0000000108925c08 facebook::react::Instance::loadScriptFromString(std::__1::unique_ptr<facebook::react::JSBigString const, std::__1::default_delete<facebook::react::JSBigString const> >, std::__1::basic_string<char,... + 72 (Instance.cpp:105)
34 React 0x000000010742ff94 __51-[RCTCxxBridge executeApplicationScript:url:async:]_block_invoke + 684 (RCTCxxBridge.mm:1367)
35 React 0x00000001074348bc std::__1::__function::__value_func<void ()>::operator()() const + 20 (functional:1880)
36 React 0x00000001074348bc std::__1::function<void ()>::operator()() const + 20 (functional:2555)
37 React 0x00000001074348bc facebook::react::tryAndReturnError(std::__1::function<void ()> const&) + 40 (RCTCxxUtils.mm:74)
38 React 0x0000000107429c38 -[RCTCxxBridge _tryAndHandleError:] + 100 (RCTCxxBridge.mm:275)
39 React 0x000000010742fc80 -[RCTCxxBridge executeApplicationScript:url:async:] + 164 (RCTCxxBridge.mm:1346)
40 React 0x000000010742fbd4 -[RCTCxxBridge executeApplicationScriptSync:url:] + 24 (RCTCxxBridge.mm:1341)
41 React 0x000000010742d538 -[RCTCxxBridge executeSourceCode:sync:] + 164 (RCTCxxBridge.mm:941)
42 SHPReactNativeSDK 0x0000000107ec1d8c -[SHPRNContainer executePluginCode:] + 236 (SHPRNContainer.m:152)
43 SHPReactNativeSDK 0x0000000107ec15a4 -[SHPRNContainer loadPluginBundle:bundleLoadCompletion:] + 492 (SHPRNContainer.m:80)
44 SHPReactNativeSDK 0x0000000107ed5fd8 -[SHPRNModeReleaseStrategies loadPlugin:bundleName:pageName:bundleLoadCompletion:] + 188 (SHPRNModeStrategies.m:63)
45 SHPReactNativeSDK 0x0000000107ec3070 __72-[SHPRNContainerManager loadPluginBundle:pageName:bundleLoadCompletion:]_block_invoke + 364 (SHPRNContainerManager.m:163)
46 SHPReactNativeSDK 0x0000000107ec3544 __72-[SHPRNContainerManager loadPluginBundle:pageName:bundleLoadCompletion:]_block_invoke.119 + 144 (SHPRNContainerManager.m:203)
47 Foundation 0x00000001820ffc10 -[__NSObserver _doit:] + 348 (NSNotification.m:327)
48 CoreFoundation 0x00000001808d2f88 __CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__ + 28 (CFNotificationCenter.c:652)
49 CoreFoundation 0x000000018096ec3c ___CFXRegistrationPost_block_invoke + 52 (CFNotificationCenter.c:173)
50 CoreFoundation 0x0000000180941ff4 _CFXRegistrationPost + 456 (CFNotificationCenter.c:199)
51 CoreFoundation 0x00000001808e8df4 _CFXNotificationPost + 716 (CFNotificationCenter.c:1147)
52 Foundation 0x00000001820e5f68 -[NSNotificationCenter postNotificationName:object:userInfo:] + 96 (NSNotification.m:560)
53 SHPReactNativeSDK 0x0000000107ec4394 __62-[SHPRNContainerManager createPreLoadContainerWithCompletion:]_block_invoke + 88 (SHPRNContainerManager.m:346)
54 SHPReactNativeSDK 0x0000000107ec1b50 -[SHPRNContainer pluginJSLoaded:] + 128 (SHPRNContainer.m:124)
55 CoreFoundation 0x00000001808d2f88 __CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__ + 28 (CFNotificationCenter.c:652)
56 CoreFoundation 0x000000018096ec3c ___CFXRegistrationPost_block_invoke + 52 (CFNotificationCenter.c:173)
57 CoreFoundation 0x0000000180941ff4 _CFXRegistrationPost + 456 (CFNotificationCenter.c:199)
58 CoreFoundation 0x00000001808e8df4 _CFXNotificationPost + 716 (CFNotificationCenter.c:1147)
59 Foundation 0x00000001820e5f68 -[NSNotificationCenter postNotificationName:object:userInfo:] + 96 (NSNotification.m:560)
60 React 0x000000010742d7a4 __39-[RCTCxxBridge executeSourceCode:sync:]_block_invoke_2 + 200 (RCTCxxBridge.mm:928)
61 libdispatch.dylib 0x00000001805b1924 _dispatch_call_block_and_release + 32 (init.c:1517)
62 libdispatch.dylib 0x00000001805b3670 _dispatch_client_callout + 20 (object.m:560)
63 libdispatch.dylib 0x00000001805c1b70 _dispatch_main_queue_callback_4CF + 944 (inline_internal.h:2601)
64 CoreFoundation 0x00000001808f9d84 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 16 (CFRunLoop.c:1795)
65 CoreFoundation 0x00000001808b3f5c __CFRunLoopRun + 2540 (CFRunLoop.c:3144)
66 CoreFoundation 0x00000001808c7468 CFRunLoopRunSpecific + 600 (CFRunLoop.c:3268)
67 GraphicsServices 0x000000019c45238c GSEventRunModal + 164 (GSEvent.c:2200)
68 UIKitCore 0x0000000183269088 -[UIApplication _run] + 1100 (UIApplication.m:3493)
69 UIKitCore 0x0000000182fe7958 UIApplicationMain + 2092 (UIApplication.m:5046)
70 ShopeeFood 0x00000001043ed73c main + 152 (main.m:19)
71 dyld 0x000000010536daa4 start + 520 (dyldMain.cpp:879)
Hope anyone can help me how to solve this problem, or give me any information about this type of crash.
Thank you very much.

Crashed: AVAudioSession Notify Thread EXC_BREAKPOINT in IOS 12 and 13

I am getting EXC_BREAKPOINT crash that occurs in the AVAudioSession Notify Thread. its happends in IOS 12 and 13 only, How to handle this?
Please have a look at crashlytics logs for more info from Firebase .
Crashed: AVAudioSession Notify Thread
0 WebKit 0x18a6b4430 WTFCrashWithInfo(int, char const*, char const*, int) + 20
1 WebKit 0x18a934484 WebKit::CallbackMap::put(WTF::Ref<WebKit::CallbackBase, WTF::DumbPtrTraits<WebKit::CallbackBase> >&&) + 312
2 WebKit 0x18a92681c WebKit::CallbackID WebKit::CallbackMap::put<API::SerializedScriptValue*, WTF::Optional<WebCore::ExceptionDetails>, WebKit::CallbackBase::Error>(WTF::Function<void (API::SerializedScriptValue*, WTF::Optional<WebCore::ExceptionDetails>, WebKit::CallbackBase::Error)>&&, WTF::Variant<std::nullptr_t, WTF::UniqueRef<WebKit::ProcessThrottler::Activity<(WebKit::ProcessThrottler::ActivityType)0> >, WTF::UniqueRef<WebKit::ProcessThrottler::Activity<(WebKit::ProcessThrottler::ActivityType)1> > >&&) + 112
3 WebKit 0x18a9266a4 WebKit::WebPageProxy::runJavaScriptInMainFrameScriptWorld(WebCore::RunJavaScriptParameters&&, WTF::Optional<WTF::String> const&, WTF::Function<void (API::SerializedScriptValue*, WTF::Optional<WebCore::ExceptionDetails>, WebKit::CallbackBase::Error)>&&) + 176
4 WebKit 0x18a9265bc WebKit::WebPageProxy::runJavaScriptInMainFrame(WebCore::RunJavaScriptParameters&&, WTF::Function<void (API::SerializedScriptValue*, WTF::Optional<WebCore::ExceptionDetails>, WebKit::CallbackBase::Error)>&&) + 32
5 WebKit 0x18a879680 -[WKWebView _evaluateJavaScript:asAsyncFunction:withArguments:forceUserGesture:completionHandler:] + 548
6 VIsualVoiceMail Production 0x1020e8d50 ViewController.audioRouteChanged() + 4363767120 (<compiler-generated>:4363767120)
7 VIsualVoiceMail Production 0x1020e9538 #objc ViewController.audioRouteChanged() + 4363769144 (<compiler-generated>:4363769144)
8 CoreFoundation 0x1830d0504 __CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__ + 20
9 CoreFoundation 0x1830d054c ___CFXRegistrationPost1_block_invoke + 64
10 CoreFoundation 0x1830cf8a4 _CFXRegistrationPost1 + 368
11 CoreFoundation 0x1830cf57c ___CFXNotificationPost_block_invoke + 88
12 CoreFoundation 0x18304c2d4 -[_CFXNotificationRegistrar find:object:observer:enumerator:] + 1412
13 CoreFoundation 0x1830ceedc _CFXNotificationPost + 1236
14 Foundation 0x18343c974 -[NSNotificationCenter postNotificationName:object:userInfo:] + 60
15 AVFAudio 0x18feec104 avfaudio::AVAudioSessionPropertyListener(void*, unsigned int, unsigned int, void const*) + 2640
16 AudioToolbox 0x18e3b5484 AudioSessionPropertyListeners::CallPropertyListeners(unsigned int, unsigned int, void const*) + 596
17 AudioToolbox 0x18e4098b0 HandleCFPropertyListChange(unsigned int, unsigned int, unsigned long, unsigned char*, unsigned int) + 696
18 AudioToolbox 0x18e40f468 HandleAudioSessionCFTypePropertyChangedMessage(unsigned int, unsigned int, void*, unsigned int) + 328
19 AudioToolbox 0x18e40eb80 ProcessDeferredMessage(unsigned int, __CFData const*, unsigned int, unsigned int) + 1620
20 AudioToolbox 0x18e40e17c ASCallbackReceiver_AudioSessionPingMessage + 632
21 AudioToolbox 0x18e47c398 _XAudioSessionPingMessage + 44
22 libAudioToolboxUtility.dylib 0x18e50f430 mshMIGPerform + 264
23 CoreFoundation 0x1830f3174 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 56
24 CoreFoundation 0x1830f2880 __CFRunLoopDoSource1 + 444
25 CoreFoundation 0x1830ed634 __CFRunLoopRun + 1888
26 CoreFoundation 0x1830ecba8 CFRunLoopRunSpecific + 424
27 AVFAudio 0x18fec3a2c GenericRunLoopThread::Entry(void*) + 156
28 AVFAudio 0x18ff147a0 CAPThread::Entry(CAPThread*) + 204
29 libsystem_pthread.dylib 0x182e8ad98 _pthread_start + 156
30 libsystem_pthread.dylib 0x182e8e74c thread_start + 8

Xcode. Unable to stop at breakpoint

I have an issue with debugging my iOS application. When the app reaches the breakpoint it stops there for a second and then the debugger crashes. (The app doesn't crash, only the debugger. A behavior similar to a device being disconnected from cable while it's in debug mode).
The print from Xcode Console:
Message from debugger: The LLDB RPC server has crashed. The crash log
is located in ~/Library/Logs/DiagnosticReports and has a prefix
'lldb-rpc-server'. Please file a bug and attach the most recent crash
log.
I checked the crash log and here's the part of the file:
Process: lldb-rpc-server [21320]
Path: /Applications/Xcode.app/Contents/SharedFrameworks/LLDBRPC.framework/Versions/A/Resources/lldb-rpc-server
Identifier: lldb-rpc-server
Version: 2
Code Type: X86-64 (Native)
Parent Process: Xcode [15500]
Responsible: lldb-rpc-server [21320]
User ID: 502
Date/Time: 2018-04-12 17:20:19.901 +0300
OS Version: Mac OS X 10.13.4 (17E199)
Report Version: 12
Anonymous UUID: BCD9F4BE-3ECF-2DD0-68EC-671CF1821432
Time Awake Since Boot: 24000 seconds
System Integrity Protection: enabled
Crashed Thread: 8 RPC packet thread for client tid 00055ab9 (350905)
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Exception Note: EXC_CORPSE_NOTIFY
Application Specific Information:
Stack dump:
0. error finding type for _T07Staging11AppDelegateCD
abort() called
Thread 8 Crashed:: RPC packet thread for client tid 00055ab9 (350905)
0 libsystem_kernel.dylib 0x00007fff70cdcb6e __pthread_kill + 10
1 libsystem_pthread.dylib 0x00007fff70ea7080 pthread_kill + 333
2 libsystem_c.dylib 0x00007fff70c3824d __abort + 144
3 libsystem_c.dylib 0x00007fff70c381bd abort + 142
4 com.apple.LLDB.framework 0x000000011132acdd swift::ModuleFile::fatal(llvm::Error) + 1213
5 com.apple.LLDB.framework 0x0000000111332711 swift::ModuleFile::getDeclChecked(llvm::PointerEmbeddedInt<unsigned int, 31>, llvm::Optional<swift::DeclContext*>) + 27649
6 com.apple.LLDB.framework 0x0000000111359e39 swift::ModuleFile::lookupValue(swift::DeclName, llvm::SmallVectorImpl<swift::ValueDecl*>&) + 841
7 com.apple.LLDB.framework 0x0000000110b43f9a swift::ModuleDecl::lookupValue(llvm::ArrayRef<std::__1::pair<swift::Identifier, swift::SourceLoc> >, swift::DeclName, swift::NLKind, llvm::SmallVectorImpl<swift::ValueDecl*>&) const + 90
8 com.apple.LLDB.framework 0x0000000110b4e8aa void lookupInModule<llvm::SmallSet<swift::CanType, 4u, (anonymous namespace)::SortCanType>, swift::namelookup::lookupInModule(swift::ModuleDecl*, llvm::ArrayRef<std::__1::pair<swift::Identifier, swift::SourceLoc> >, swift::DeclName, llvm::SmallVectorImpl<swift::ValueDecl*>&, swift::NLKind, swift::namelookup::ResolutionKind, swift::LazyResolver*, swift::DeclContext const*, llvm::ArrayRef<std::__1::pair<llvm::ArrayRef<std::__1::pair<swift::Identifier, swift::SourceLoc> >, swift::ModuleDecl*> >)::$_0>(swift::ModuleDecl*, llvm::ArrayRef<std::__1::pair<swift::Identifier, swift::SourceLoc> >, llvm::SmallVectorImpl<swift::ValueDecl*>&, swift::namelookup::ResolutionKind, bool, swift::LazyResolver*, llvm::SmallDenseMap<std::__1::pair<llvm::ArrayRef<std::__1::pair<swift::Identifier, swift::SourceLoc> >, swift::ModuleDecl*>, llvm::TinyPtrVector<swift::ValueDecl*>, 32u, llvm::DenseMapInfo<std::__1::pair<llvm::ArrayRef<std::__1::pair<swift::Identifier, swift::SourceLoc> >, swift::ModuleDecl*> >, llvm::detail::DenseMapPair<std::__1::pair<llvm::ArrayRef<std::__1::pair<swift::Identifier, swift::SourceLoc> >, swift::ModuleDecl*>, llvm::TinyPtrVector<swift::ValueDecl*> > >&, swift::DeclContext const*, bool, llvm::ArrayRef<std::__1::pair<llvm::ArrayRef<std::__1::pair<swift::Identifier, swift::SourceLoc> >, swift::ModuleDecl*> >, swift::namelookup::lookupInModule(swift::ModuleDecl*, llvm::ArrayRef<std::__1::pair<swift::Identifier, swift::SourceLoc> >, swift::DeclName, llvm::SmallVectorImpl<swift::ValueDecl*>&, swift::NLKind, swift::namelookup::ResolutionKind, swift::LazyResolver*, swift::DeclContext const*, llvm::ArrayRef<std::__1::pair<llvm::ArrayRef<std::__1::pair<swift::Identifier, swift::SourceLoc> >, swift::ModuleDecl*> >)::$_0) + 346
9 com.apple.LLDB.framework 0x0000000110b4e71e swift::namelookup::lookupInModule(swift::ModuleDecl*, llvm::ArrayRef<std::__1::pair<swift::Identifier, swift::SourceLoc> >, swift::DeclName, llvm::SmallVectorImpl<swift::ValueDecl*>&, swift::NLKind, swift::namelookup::ResolutionKind, swift::LazyResolver*, swift::DeclContext const*, llvm::ArrayRef<std::__1::pair<llvm::ArrayRef<std::__1::pair<swift::Identifier, swift::SourceLoc> >, swift::ModuleDecl*> >) + 1278
10 com.apple.LLDB.framework 0x0000000110b550e1 swift::DeclContext::lookupQualified(swift::Type, swift::DeclName, swift::NLOptions, swift::LazyResolver*, llvm::SmallVectorImpl<swift::ValueDecl*>&) const + 1089
11 com.apple.LLDB.framework 0x0000000110c56db2 DeclsLookupSource::lookupQualified(swift::Identifier, swift::NLOptions, swift::LazyResolver*, llvm::SmallVectorImpl<swift::ValueDecl*>&) + 226
12 com.apple.LLDB.framework 0x0000000110c5693d FindFirstNamedDeclWithKind(swift::ASTContext*, llvm::StringRef const&, swift::DeclKind, VisitNodeResult&, llvm::Optional<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >) + 301
13 com.apple.LLDB.framework 0x0000000110c5608c VisitNodeIdentifier(swift::ASTContext*, swift::Demangle::Node*, swift::Demangle::Node*, VisitNodeResult&) + 124
14 com.apple.LLDB.framework 0x0000000110c4ebf7 VisitNode(swift::ASTContext*, swift::Demangle::Node*, VisitNodeResult&) + 199
15 com.apple.LLDB.framework 0x0000000110c4eba0 VisitNode(swift::ASTContext*, swift::Demangle::Node*, VisitNodeResult&) + 112
16 com.apple.LLDB.framework 0x0000000110c4eba0 VisitNode(swift::ASTContext*, swift::Demangle::Node*, VisitNodeResult&) + 112
17 com.apple.LLDB.framework 0x0000000110c4eba0 VisitNode(swift::ASTContext*, swift::Demangle::Node*, VisitNodeResult&) + 112
18 com.apple.LLDB.framework 0x0000000110c5475c swift::ide::getTypeFromMangledSymbolname(swift::ASTContext&, llvm::StringRef, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >&) + 204
19 com.apple.LLDB.framework 0x000000011172ceda lldb_private::SwiftASTContext::GetTypeFromMangledTypename(char const*, lldb_private::Error&) + 532
20 com.apple.LLDB.framework 0x00000001114a5101 DWARFASTParserSwift::ParseTypeFromDWARF(lldb_private::SymbolContext const&, DWARFDIE const&, lldb_private::Log*, bool*) + 887
21 com.apple.LLDB.framework 0x00000001115c2623 SymbolFileDWARF::ParseType(lldb_private::SymbolContext const&, DWARFDIE const&, bool*) + 171
22 com.apple.LLDB.framework 0x00000001115bc33f SymbolFileDWARF::GetTypeForDIE(DWARFDIE const&, bool) + 369
23 com.apple.LLDB.framework 0x00000001115bbc6e SymbolFileDWARF::ResolveType(DWARFDIE const&, bool, bool) + 68
24 com.apple.LLDB.framework 0x00000001115bbbed SymbolFileDWARF::ResolveTypeUID(unsigned long long) + 45
25 com.apple.LLDB.framework 0x00000001116390d7 lldb_private::SymbolFileType::GetType() + 51
26 com.apple.LLDB.framework 0x000000011147be4f lldb_private::ValueObjectVariable::GetCompilerTypeImpl() + 21
27 com.apple.LLDB.framework 0x000000011146cf67 lldb_private::ValueObject::MaybeCalculateCompleteType() + 39
28 com.apple.LLDB.framework 0x00000001114712dd lldb_private::ValueObject::GetObjectRuntimeLanguage() + 33
29 com.apple.LLDB.framework 0x000000011147167b lldb_private::ValueObject::IsRuntimeSupportValue() + 73
30 com.apple.LLDB.framework 0x000000010eb3faec lldb::SBFrame::GetVariables(lldb::SBVariablesOptions const&) + 624
31 com.apple.LLDB.framework 0x000000010eb3fda4 lldb::SBFrame::GetVariables(bool, bool, bool, bool, lldb::DynamicValueType) + 208
32 lldb-rpc-server 0x000000010e8b0aef rpc_server::_ZN4lldb7SBFrame12GetVariablesEbbbbNS_16DynamicValueTypeE::HandleRPCCall(rpc_common::Connection&, rpc_common::RPCStream&, rpc_common::RPCStream&) + 219
33 lldb-rpc-server 0x000000010e87662a rpc_common::Connection::PrivateHandleRPCPacket(rpc_common::RPCPacket&, rpc_common::RPCPacket&, bool&) + 506
34 lldb-rpc-server 0x000000010e87730c rpc_common::Connection::HandleRPCPacket(rpc_common::RPCPacket&) + 62
35 lldb-rpc-server 0x000000010e87a862 Packets::ProcessPackets() + 254
36 lldb-rpc-server 0x000000010e87a68b Packets::ReadThread() + 187
37 lldb-rpc-server 0x000000010e87a5cb Packets::RunReadThread(void*) + 9
38 libsystem_pthread.dylib 0x00007fff70ea4661 _pthread_body + 340
39 libsystem_pthread.dylib 0x00007fff70ea450d _pthread_start + 377
40 libsystem_pthread.dylib 0x00007fff70ea3bf9 thread_start + 13
(the full output could be found here)
https://pastebin.com/18ZE08kv
Line 28 says:
error finding type for _T07Staging11AppDelegateCD
Does anybody know, what the error means?
Any help would be appreciated.
Regards
Just move your breakpoint by a line. Clean the project and try to run again, it should solve your problem.

ios - webthread- java script core crash

getting lots of crashes as below in ios11: any idea what could be reason behind it. its happening in ios11 only. webkit framework is included in project.
Crashed: WebThread
0 JavaScriptCore 0x18d513a2c bmalloc::Heap::allocateLarge(std::__1::lock_guard<bmalloc::StaticMutex>&, unsigned long, unsigned long) + 24
1 JavaScriptCore 0x18d513a20 bmalloc::Heap::allocateLarge(std::__1::lock_guard<bmalloc::StaticMutex>&, unsigned long, unsigned long) + 12
2 JavaScriptCore 0x18d5112a0 bmalloc::Allocator::allocateLarge(unsigned long) + 92
3 JavaScriptCore 0x18cb6bef4 WTF::fastMalloc(unsigned long) + 112
4 JavaScriptCore 0x18d11e6a8 JSC::Heap::addExecutable(JSC::ExecutableBase*) + 352
5 JavaScriptCore 0x18d10a288 JSC::FunctionExecutable::finishCreation(JSC::VM&) + 48
6 JavaScriptCore 0x18d44f7cc JSC::UnlinkedFunctionExecutable::link(JSC::VM&, JSC::SourceCode const&, std::optional<int>, JSC::Intrinsic) + 280
7 JavaScriptCore 0x18d207860 JSC::functionPrototypeApplyCodeGenerator(JSC::VM&) + 64
8 JavaScriptCore 0x18d10d81c JSC::FunctionPrototype::addFunctionProperties(JSC::ExecState*, JSC::JSGlobalObject*, JSC::JSFunction**, JSC::JSFunction**, JSC::JSFunction**) + 156
9 JavaScriptCore 0x18d21a9f8 JSC::JSGlobalObject::init(JSC::VM&) + 1300
10 JavaScriptCore 0x18d224898 JSC::JSGlobalObject::finishCreation(JSC::VM&, JSC::JSObject*) + 144
11 WebCore 0x18e015590 WebCore::JSDOMGlobalObject::finishCreation(JSC::VM&, JSC::JSObject*) + 24
12 WebCore 0x18e850840 WebCore::JSDOMWindowBase::finishCreation(JSC::VM&, WebCore::JSDOMWindowProxy*) + 44
13 WebCore 0x18e7d28ac WebCore::JSDOMWindow::finishCreation(JSC::VM&, WebCore::JSDOMWindowProxy*) + 36
14 WebCore 0x18e8548a4 WebCore::JSDOMWindowProxy::setWindow(WTF::RefPtr<WebCore::DOMWindow>&&) + 516
15 WebCore 0x18eed505c WebCore::ScriptController::setDOMWindowForWindowProxy(WebCore::DOMWindow*) + 360
16 WebCore 0x18dfed904 WebCore::FrameLoader::clear(WebCore::Document*, bool, bool, bool) + 476
17 WebCore 0x18e3a42c8 WebCore::DocumentWriter::begin(WebCore::URL const&, bool, WebCore::Document*) + 368
18 WebCore 0x18dfebb58 WebCore::DocumentLoader::commitData(char const*, unsigned long) + 176
19 WebKitLegacy 0x18f3d3bd8 -[WebHTMLRepresentation receivedData:withDataSource:] + 112
20 WebKitLegacy 0x18f3d3af8 -[WebDataSource(WebInternal) _receivedData:] + 68
21 WebKitLegacy 0x18f3d3a98 WebFrameLoaderClient::committedLoad(WebCore::DocumentLoader*, char const*, int) + 112
22 WebCore 0x18e0099c4 WebCore::DocumentLoader::commitLoad(char const*, int) + 172
23 WebCore 0x18e008bec WebCore::DocumentLoader::continueAfterContentPolicy(WebCore::PolicyAction) + 1796
24 WebCore 0x18e3930a0 WebCore::DocumentLoader::responseReceived(WebCore::ResourceResponse const&) + 1820
25 WebCore 0x18e392004 WebCore::DocumentLoader::handleSubstituteDataLoadNow() + 308
26 WebCore 0x18dfaf000 WebCore::ThreadTimers::sharedTimerFiredInternal() + 172
27 WebCore 0x18dfaef40 WebCore::timerFired(__CFRunLoopTimer*, void*) + 28
28 CoreFoundation 0x186152fc0 __CFRUNLOOP_IS_CALLING_OUT_TO_A_TIMER_CALLBACK_FUNCTION__ + 28
29 CoreFoundation 0x186152ce4 __CFRunLoopDoTimer + 864
30 CoreFoundation 0x1861524e4 __CFRunLoopDoTimers + 248
31 CoreFoundation 0x1861500cc __CFRunLoopRun + 1928
32 CoreFoundation 0x18606fe58 CFRunLoopRunSpecific + 436
33 WebCore 0x18dfe0a34 RunWebThread(void*) + 560
34 libsystem_pthread.dylib 0x185dd02b4 _pthread_body + 308
35 libsystem_pthread.dylib 0x185dd0180 _pthread_body + 310
36 libsystem_pthread.dylib 0x185dceb74 thread_start + 4

App Crashes after executing background fetch completionHandler

I have updated our app for iOS 7 and added the background fetch functionality. However, i'm noticing some crashes because of this feature. After background fetch call is completed, the completion handler block is executed with either new/no data. This results in a call to 'layoutSubviews' of my custom navigation NavigationBar and sometimes app is crashing with the following stack trace. I could not reproduce this issue myself but constantly receiving these crash logs from our users. Any help would be appreciated.
Thread 0 Crashed:
0 libsystem_platform.dylib 0x39cba486 _platform_memmove$VARIANT$Swift + 102
1 Foundation 0x2fce8f47 -[NSData(NSData) getBytes:range:] + 419
2 CoreFoundation 0x2f30637d CFDataGetBytes + 205
3 ImageIO 0x300e7357 CGImageReadGetBytesAtOffset + 283
4 ImageIO 0x300e7231 CGImageReadSessionGetBytes + 29
5 ImageIO 0x3022baeb read_fn + 23
6 ImageIO 0x300e7189 png_read_sig + 45
7 ImageIO 0x300e6e0d _cg_png_read_info + 33
8 ImageIO 0x300ef62f copyImageBlockSetPNG + 1123
9 ImageIO 0x300eec4b ImageProviderCopyImageBlockSetCallback + 539
10 CoreGraphics 0x2f43577d CGImageProviderCopyImageBlockSetWithOptions + 137
11 CoreGraphics 0x2f43a145 subImageProviderCopyImageBlockSet + 305
12 CoreGraphics 0x2f43577d CGImageProviderCopyImageBlockSetWithOptions + 137
13 CoreGraphics 0x2f435433 img_blocks_create + 383
14 CoreGraphics 0x2f4286fd img_data_lock + 1053
15 CoreGraphics 0x2f427ae1 CGSImageDataLock + 89
16 libRIP.A.dylib 0x2f774da7 ripc_AcquireImage + 99
17 libRIP.A.dylib 0x2f774131 ripc_DrawImage + 601
18 CoreGraphics 0x2f4279f3 CGContextDelegateDrawImage + 51
19 CoreGraphics 0x2f427879 CGContextDrawImage + 285
20 WebCore 0x373120db WebCore::GraphicsContext::drawNativeImage(CGImage*, WebCore::FloatSize const&, WebCore::ColorSpace, WebCore::FloatRect const&, WebCore::FloatRect const&, float, WebCore::CompositeOperator, WebCore::BlendMode, WebCore::ImageOrientation) + 1127
21 WebCore 0x37310e79 WebCore::BitmapImage::draw(WebCore::GraphicsContext*, WebCore::FloatRect const&, WebCore::FloatRect const&, WebCore::ColorSpace, WebCore::CompositeOperator, WebCore::BlendMode, WebCore::RespectImageOrientationEnum) + 349
22 WebCore 0x3735d897 WebCore::BitmapImage::draw(WebCore::GraphicsContext*, WebCore::FloatRect const&, WebCore::FloatRect const&, WebCore::ColorSpace, WebCore::CompositeOperator, WebCore::BlendMode) + 31
23 WebCore 0x3735892f WebCore::Image::drawTiled(WebCore::GraphicsContext*, WebCore::FloatRect const&, WebCore::FloatPoint const&, WebCore::FloatSize const&, WebCore::ColorSpace, WebCore::CompositeOperator, WebCore::BlendMode) + 499
24 WebCore 0x37358735 WebCore::GraphicsContext::drawTiledImage(WebCore::Image*, WebCore::ColorSpace, WebCore::IntRect const&, WebCore::IntPoint const&, WebCore::IntSize const&, WebCore::CompositeOperator, bool, WebCore::BlendMode) + 193
25 WebCore 0x3728bc11 WebCore::RenderBoxModelObject::paintFillLayerExtended(WebCore::PaintInfo const&, WebCore::Color const&, WebCore::FillLayer const*, WebCore::LayoutRect const&, WebCore::BackgroundBleedAvoidance, WebCore::InlineFlowBox*, WebCore::LayoutSize const&, WebCore::CompositeOperator, WebCore::RenderObject*) + 3321
26 WebCore 0x3728addd WebCore::RenderBox::paintFillLayers(WebCore::PaintInfo const&, WebCore::Color const&, WebCore::FillLayer const*, WebCore::LayoutRect const&, WebCore::BackgroundBleedAvoidance, WebCore::CompositeOperator, WebCore::RenderObject*) + 449
27 WebCore 0x3728ab41 WebCore::RenderBox::paintBackground(WebCore::PaintInfo const&, WebCore::LayoutRect const&, WebCore::BackgroundBleedAvoidance) + 317
28 WebCore 0x37289ee5 WebCore::RenderBox::paintBoxDecorations(WebCore::PaintInfo&, WebCore::LayoutPoint const&) + 329
29 WebCore 0x3728806f WebCore::RenderBlock::paintObject(WebCore::PaintInfo&, WebCore::LayoutPoint const&) + 55
30 WebCore 0x37289c3f WebCore::RenderBlock::paint(WebCore::PaintInfo&, WebCore::LayoutPoint const&) + 187
31 WebCore 0x37288cc9 WebCore::RenderBlock::paintFloats(WebCore::PaintInfo&, WebCore::LayoutPoint const&, bool) + 305
32 WebCore 0x3728813d WebCore::RenderBlock::paintObject(WebCore::PaintInfo&, WebCore::LayoutPoint const&) + 261
33 WebCore 0x37289c3f WebCore::RenderBlock::paint(WebCore::PaintInfo&, WebCore::LayoutPoint const&) + 187
34 WebCore 0x37288cfb WebCore::RenderBlock::paintFloats(WebCore::PaintInfo&, WebCore::LayoutPoint const&, bool) + 355
35 WebCore 0x3728813d WebCore::RenderBlock::paintObject(WebCore::PaintInfo&, WebCore::LayoutPoint const&) + 261
36 WebCore 0x37289c3f WebCore::RenderBlock::paint(WebCore::PaintInfo&, WebCore::LayoutPoint const&) + 187
37 WebCore 0x37288861 WebCore::RenderLayer::paintForegroundForFragmentsWithPhase(WebCore::PaintPhase, WTF::Vector<WebCore::LayerFragment, 1ul, WTF::CrashOnOverflow> const&, WebCore::GraphicsContext*, WebCore::RenderLayer::LayerPaintingInfo const&, unsigned int, WebCore::RenderObject*) + 269
38 WebCore 0x372886e7 WebCore::RenderLayer::paintForegroundForFragments(WTF::Vector<WebCore::LayerFragment, 1ul, WTF::CrashOnOverflow> const&, WebCore::GraphicsContext*, WebCore::GraphicsContext*, WebCore::LayoutRect const&, bool, WebCore::RenderLayer::LayerPaintingInfo const&, unsigned int, WebCore::RenderObject*, bool, bool) + 235
39 WebCore 0x37286435 WebCore::RenderLayer::paintLayerContents(WebCore::GraphicsContext*, WebCore::RenderLayer::LayerPaintingInfo const&, unsigned int) + 1585
40 WebCore 0x37285ca9 WebCore::RenderLayer::paintLayer(WebCore::GraphicsContext*, WebCore::RenderLayer::LayerPaintingInfo const&, unsigned int) + 621
41 WebCore 0x372885d9 WebCore::RenderLayer::paintList(WTF::Vector<WebCore::RenderLayer*, 0ul, WTF::CrashOnOverflow>*, WebCore::GraphicsContext*, WebCore::RenderLayer::LayerPaintingInfo const&, unsigned int) + 101
42 WebCore 0x3728647f WebCore::RenderLayer::paintLayerContents(WebCore::GraphicsContext*, WebCore::RenderLayer::LayerPaintingInfo const&, unsigned int) + 1659
43 WebCore 0x37285ca9 WebCore::RenderLayer::paintLayer(WebCore::GraphicsContext*, WebCore::RenderLayer::LayerPaintingInfo const&, unsigned int) + 621
44 WebCore 0x372885d9 WebCore::RenderLayer::paintList(WTF::Vector<WebCore::RenderLayer*, 0ul, WTF::CrashOnOverflow>*, WebCore::GraphicsContext*, WebCore::RenderLayer::LayerPaintingInfo const&, unsigned int) + 101
45 WebCore 0x3728647f WebCore::RenderLayer::paintLayerContents(WebCore::GraphicsContext*, WebCore::RenderLayer::LayerPaintingInfo const&, unsigned int) + 1659
46 WebCore 0x37285ca9 WebCore::RenderLayer::paintLayer(WebCore::GraphicsContext*, WebCore::RenderLayer::LayerPaintingInfo const&, unsigned int) + 621
47 WebCore 0x372859b3 WebCore::RenderLayer::paint(WebCore::GraphicsContext*, WebCore::LayoutRect const&, unsigned int, WebCore::RenderObject*, WebCore::RenderRegion*, unsigned int) + 103
48 WebCore 0x3728541b WebCore::FrameView::paintContents(WebCore::GraphicsContext*, WebCore::IntRect const&) + 499
49 WebKit 0x37c4578d -[WebFrame(WebInternal) _drawRect:contentsOnly:] + 357
50 WebKit 0x37c455b9 -[WebHTMLView drawSingleRect:] + 137
51 WebKit 0x37c454db -[WebHTMLView drawRect:] + 43
52 WebCore 0x37284d93 -[WAKView _drawRect:context:lockFocus:] + 275
53 WebCore 0x37284ec7 -[WAKView _drawRect:context:lockFocus:] + 583
54 WebCore 0x37284ec7 -[WAKView _drawRect:context:lockFocus:] + 583
55 WebCore 0x37284ec7 -[WAKView _drawRect:context:lockFocus:] + 583
56 WebCore 0x37284ec7 -[WAKView _drawRect:context:lockFocus:] + 583
57 WebCore 0x37284c47 -[WAKView displayRect:] + 59
58 WebCore 0x37284c03 -[WAKWindow displayRect:] + 55
59 WebCore 0x37284b49 WebCore::TileCache::drawWindowContent(TileLayer*, CGContext*, CGRect) + 673
60 WebCore 0x37284525 WebCore::TileCache::drawLayer(TileLayer*, CGContext*) + 505
61 QuartzCore 0x317d3813 CABackingStoreUpdate_ + 1859
62 QuartzCore 0x318ad735 ___ZN2CA5Layer8display_Ev_block_invoke + 53
63 QuartzCore 0x317d30c3 x_blame_allocations + 83
64 QuartzCore 0x317d2d77 CA::Layer::display_() + 1119
65 QuartzCore 0x317b6969 CA::Layer::display_if_needed(CA::Transaction*) + 209
66 QuartzCore 0x317b6601 CA::Layer::layout_and_display_if_needed(CA::Transaction*) + 25
67 QuartzCore 0x317b600d CA::Context::commit_transaction(CA::Transaction*) + 229
68 QuartzCore 0x317b5e1f CA::Transaction::commit() + 315
69 UIKit 0x31d973c9 _UIWindowUpdateVisibleContextOrder + 209
70 UIKit 0x31d9729d +[UIWindow _prepareWindowsPassingTestForAppResume:] + 13
71 UIKit 0x31db0ac5 -[UIApplication _updateSnapshotAndStateRestorationArchiveForBackgroundEvent:saveState:exitIfCouldNotRestoreState:] + 201
72 UIKit 0x31db0d81 -[UIApplication _replyToBackgroundFetchRequestWithResult:remoteNotificationToken:sequenceNumber:updateApplicationSnapshot:] + 105
73 UIKit 0x31db138d __61-[UIApplication _handleOpportunisticFetchWithSequenceNumber:]_block_invoke + 37
74 MyApp 0x001456b7 -[List fetched:error:withBackgroundFetchCompletionHandler:] (List.m:421)
75 MyApp 0x00144f87 __71-[List fetchFromServerWithBackgroundFetchCompletionHandler:]_block_invoke (List.m:292)
76 MyApp 0x0021ed07 APICompletionBlock_block_invoke_6 (APIRequest.m:305)
77 libdispatch.dylib 0x39b8c103 _dispatch_call_block_and_release + 11
78 libdispatch.dylib 0x39b8c0ef _dispatch_client_callout + 23
79 libdispatch.dylib 0x39b8e9a9 _dispatch_main_queue_callback_4CF + 269
80 CoreFoundation 0x2f3785b9 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 9
81 CoreFoundation 0x2f376e85 __CFRunLoopRun + 1309
82 CoreFoundation 0x2f2e1541 CFRunLoopRunSpecific + 525
83 CoreFoundation 0x2f2e1323 CFRunLoopRunInMode + 107
84 GraphicsServices 0x340182eb GSEventRunModal + 139
85 UIKit 0x31b981e5 UIApplicationMain + 1137
86 MyApp 0x0009f77f main (main.m:14)
When you leave your app to the background, it saves the snapshot of the current view to the memory so it could be shown when you double-click the home button.
With the iOS7 background refresh feature ((void)application:(UIApplication *)application didReceiveRemoteNotification:(NSDictionary *)userInfo fetchCompletionHandler:(void (^)(UIBackgroundFetchResult result))completionHandler), you must execute the completionHandler function after you finish executing your fetch request.
The execution of that function also triggers updates to the UI - [UIApplication _updateSnapshotAndStateRestorationArchiveForBackgroundEvent:saveState:exitIfCouldNotRestoreState:], and in your case it triggers calculating the frame for a UIWebView from a background thread.
UIWebView can be updated only from the UIThread, so to overcome this crash I would suggest to wrap the completionHandler with execution on the main thread:
- (void)application:(UIApplication *)application didReceiveRemoteNotification:(NSDictionary *)userInfo fetchCompletionHandler:(void (^)(UIBackgroundFetchResult result))completionHandler
{
void (^safeHandler)(UIBackgroundFetchResult) = ^(UIBackgroundFetchResult result){
dispatch_async(dispatch_get_main_queue(), ^{
completionHandler(result);
});
};
[someInstance doSomethingInBackground:userInfo withHandler:safeHandler];
}
And you will no longer have to worry where you invoke the completionHandler (now safeHandler) from.

Resources