I have a random crash in my app in launching.
I'm pretty sure is not the launching time (as explained in What does 8badf00d mean?) because the app launch fast.
The worst is that the crash log can't be simbolicate (I can't get the sourcecode line numbers). This is the error:
Exception Type: 00000020
Exception Codes: 0x8badf00d
Highlighted Thread: 0
Application Specific Information:
Failed to launch
Thread 0:
0 JhonSell 0x000c63d6 0x1000 + 807894
1 JhonSell 0x000c7ffe 0x1000 + 815102
2 JhonSell 0x000c9646 0x1000 + 820806
3 JhonSell 0x000ca50a 0x1000 + 824586
4 JhonSell 0x000b3b72 0x1000 + 732018
5 JhonSell 0x000b3e1e 0x1000 + 732702
6 JhonSell 0x000b3fd4 0x1000 + 733140
7 JhonSell 0x0000a312 0x1000 + 37650
8 JhonSell 0x0000aa7c 0x1000 + 39548
9 JhonSell 0x00006e7c 0x1000 + 24188
10 JhonSell 0x0000fede 0x1000 + 61150
11 JhonSell 0x00004080 0x1000 + 12416
12 UIKit 0x30a4ef24 -[UIApplication performInitializationWithURL:asPanel:] + 160
13 UIKit 0x30a57dec -[UIApplication _runWithURL:] + 644
14 Foundation 0x306945a2 __NSFireDelayedPerform + 326
15 CoreFoundation 0x30269d88 CFRunLoopRunSpecific + 2642
16 CoreFoundation 0x30269320 CFRunLoopRunInMode + 44
17 GraphicsServices 0x31567e58 GSEventRunModal + 268
18 UIKit 0x30a4fa6c -[UIApplication _run] + 520
19 UIKit 0x30a591d0 UIApplicationMain + 1132
20 JhonSell 0x00002290 0x1000 + 4752
21 JhonSell 0x0000202c 0x1000 + 4140
I can't debug it (I try to attach but the app get killed by the watchdog, I think).
There are three methods in your UIApplicationDelegate implementation that have to finish within 5-6 seconds or the iPhone will kill your application (this does not apply to when you are attached with a debugger and on the simulator). I'm not sure if the exact time interval is documented anywhere, but that's what I determined experimentally. There are two on startup, applicationDidFinishLaunching: and application:didFinishLaunchingWithOptions, and one on shutdown, applicationWillTerminate.
You'll want to check out that any network access or time-consuming operations in those methods are performed asynchronously, so that the method can return quickly.
That's the only thing I know of that would cause watchdog crashes on startup.
As for more hints on the stack trace, if you are using OS 3.0 and the 3.0 SDK, Organizer should do this before. Just make sure you're keeping the dSYM files from the -exact- build available on the hard drive to spotlight somewhere. Then when you look @ the trace under the Organizer in XCode, it should add symbols automatically for you.
8BADF00D Used by Apple as the exception code in iPhone crash reports when an application has taken too long to launch or terminate.
See also
DEADFA11 Used by Apple as the exception code in iPhone crash reports when the user has force-quit the application
Apple's iPhone crash reporting document suggests that is this error code indicates a watchdog timeout:
Watchdog timeout: distinguished by exception code 0x8badf00d, timeouts occur when an application takes too long to launch or terminate.
Seeing as the crash report also states the same thing; it seems pretty likely that's what is happening. Maybe it's not application launching; but terminating - the iPhone OS expects to be able to terminate applications very quickly (e.g. to drop back to the OS when an incoming call is received) - perhaps your app is taking too long to shutdown?
With regards to your lack of symbols in the backtrace - have you looked at the Symbolicate utility?
You can check the bottom of this Apple Technical note for Apple's explanation: http://developer.apple.com/library/ios/#technotes/tn2151/_index.html
Also, screenshotted here: http://cl.ly/19391r1x213u0U440t17
Seems to me that you "ate bad food" (get it? 8 bad f00d?)
Anyway, to my understanding this means that you're using an uninitialized pointer in your application, from the looks of it in the initialization of it.
(or in any case, that's what it seems the guy in the comment says here)
User contributions licensed under CC BY-SA 3.0