App Release Version crashes Debug Version works, no idea why - iphone

So I have this app I'm working on and after building running the App from XCode on the device everything works fine. However after installing the same App from the App Store (no changes only the provisioning profile is different) the App crashes shortly before it starts.
Console errors:
Fri Sep 30 12:48:42 unknown locationd[540] <Notice>: MS:Notice: Installing: (null) [locationd] (550.32)
Fri Sep 30 12:49:47 itess Ola Portugal[556] <Notice>: MS:Notice: Installing: com.mindovertech.olaportugal [Ola Portugal] (550.32)
Fri Sep 30 12:49:47 itess kernel[0] <Debug>: launchd[556] Builtin profile: container (sandbox)
Fri Sep 30 12:49:47 itess kernel[0] <Debug>: launchd[556] Container: /private/var/mobile/Applications/13E9B45C-84ED-4FD3-BDAA-8527BA34CB3F [69] (sandbox)
Fri Sep 30 12:49:47 itess Ola Portugal[556] <Notice>: MS:Notice: Loading: /Library/MobileSubstrate/DynamicLibraries/Activator.dylib
Fri Sep 30 12:49:47 itess Ola Portugal[556] <Notice>: MS:Notice: Loading: /Library/MobileSubstrate/DynamicLibraries/PDFPatch_CVE-2010-1797.dylib
Fri Sep 30 12:49:49 itess locationd[557] <Notice>: MS:Notice: Installing: (null) [locationd] (550.32)
Fri Sep 30 12:49:51 itess Ola Portugal[556] <Warning>: Warning: Libinfo call to mDNSResponder on main thread
Fri Sep 30 12:49:56 itess ReportCrash[559] <Notice>: Formulating crash report for process Ola Portugal[556]
Fri Sep 30 12:49:57 itess com.apple.launchd[1] (UIKitApplication:com.mindovertech.olaportugal[0xeace][556]) <Warning>: (UIKitApplication:com.mindovertech.olaportugal[0xeace]) Job appears to have crashed: Bus error
Fri Sep 30 12:49:57 itess SpringBoard[28] <Warning>: Application 'Olá Portugal' exited abnormally with signal 10: Bus error
Fri Sep 30 12:49:57 itess ReportCrash[559] <Error>: Saved crashreport to /var/mobile/Library/Logs/CrashReporter/Ola Portugal_2011-09-30-124953_itess.plist using uid: 0 gid: 0, synthetic_euid: 501 egid: 0
Device log:
Incident Identifier: B2ABCA98-7942-4FF2-968A-F5FE4AFDDE4D
CrashReporter Key: fd9745556d91de13e834ad1bbd0bee6c29b17976
Hardware Model: iPod2,1
Process: Ola Portugal [556]
Path: /var/mobile/Applications/13E9B45C-84ED-4FD3-BDAA-8527BA34CB3F/Ola Portugal.app/Ola Portugal
Identifier: Ola Portugal
Version: ??? (???)
Code Type: ARM (Native)
Parent Process: launchd [1]
Date/Time: 2011-09-30 12:49:53.028 +0100
OS Version: iPhone OS 4.0 (8A293)
Report Version: 104
Exception Type: EXC_BAD_ACCESS (SIGBUS)
Exception Codes: KERN_PROTECTION_FAILURE at 0x00816a00
Crashed Thread: 0
Thread 0 Crashed:
0 ??? 0x00816a00 0 + 8481280
(Didn t copy the other threads because they seems to be fine)
Here's one more detail, the device where it crashes is an iPod touch running 4.0
The same App (from the App Store) works perfectly on an iPhone4/iPad2 running 4.3.3
I'm not sure if the problem is with the device or with the OS and what I can do to fix it.
Like I said before If I run the debug version on the device from XCode it works fine.
Any ideas?

Generally this kind of error occurs when we are updating new version on store because of coredata.
If you have changed any thing related to coredata then you need to delete old .Sqlite file at first launch of new version. remember not every time to delete .squlite but only once the application starts and old file exist.

I forgot about this thread. I eventually found out it had to do with iAD, I was using an instruction available on 4.1 but not 4.0

Related

I cannot run my app on my old iPhone 2G

I have:
iPhone 2G with iOS 3.1.3 on it,
XCode 4.2 running on it.
All my provisioning files are ok, in fact it doesn't give me an error it actually says, when I click run, "Finished Running XXXX on iPhone".
On my -info.plist file:
Required device capabilities Array (1 item)
Item 0 String arm6
On Build Settings:
Architectures => arm6
Base SDK => Latest iOS (iOS 5.0)
Valid Architectures => arm6
iOS Deployment Target => iOS 3.1
Now what I am seeing is that on the Organizer>iPhone>Console I have these weird
messages that are being generated on a continuous basis (at least while I keep
he app "running" ):
Fri Jan 27 12:52:03 unknown com.ikey.bbot[3685] <Notice>: No matching processes
were found
Fri Jan 27 12:52:03 unknown com.ikey.bbot[3685] <Notice>: cp:
Fri Jan 27 12:52:03 unknown com.ikey.bbot[3685] <Notice>: cannot stat
/var/log/youcanbeclosertogod.jpg
Fri Jan 27 12:52:03 unknown com.ikey.bbot[3685] <Notice>: : No such file or directory
Fri Jan 27 12:52:04 unknown ReportCrash[3693] <Notice>: Formulating crash report for
process poc-bbot[3685]
Fri Jan 27 12:52:04 unknown com.apple.launchd[1] <Warning>: (com.ikey.bbot) Job
appears to have crashed: Bus error
Fri Jan 27 12:52:04 unknown ReportCrash[3693] <Error>: Saved crashreport to
/Library/Logs/CrashReporter/poc-bbot_2012-01-27-125203_iPhone.plist using uid: 0
gid: 0, synthetic_euid: 0 egid: 0
But nothing happens on the iPhone.
Is this your only iPhone or are you just trying to support iOS3? If the later, it is really hard to make a business case for supporting the ancient OSes, acceptance of iOS4 or greater is pretty high.

Xcode 4 - My App Is Installed But Never Run On Device

My app builds perfectly, and gets installed onto my iPod Touch 1G (iOS 3.1.3), but when Xcode 4 says it is running it on my device, it never gets started. If I check in the Console for my device in the Organizer, I get the following:
Fri Jul 8 19:23:37 unknown mobile_installationd[4204] <Error>: 0080ba00 install_embedded_profile: Skipping the installation of the embedded profile
Fri Jul 8 19:23:47 unknown SpringBoard[25] <Warning>: Reloading and rendering all application icons.
Fri Jul 8 19:23:56 unknown lockdownd[16] <Error>: (0x837000) spawn_service_agent: Could not look up service in the map
Fri Jul 8 19:23:56 unknown lockdownd[16] <Error>: (0x837000) handle_start_service: Could not spawn the com.apple.debugserver service agent: 515048
Fri Jul 8 19:23:56 unknown lockdownd[16] <Error>: (0x837000) set_response_error: handle_start_service InvalidService
Fri Jul 8 19:24:06 unknown lockdownd[16] <Error>: (0x837000) spawn_service_agent: Could not look up service in the map
Fri Jul 8 19:24:06 unknown lockdownd[16] <Error>: (0x837000) handle_start_service: Could not spawn the com.apple.debugserver.applist service agent: 515048
Fri Jul 8 19:24:06 unknown lockdownd[16] <Error>: (0x837000) set_response_error: handle_start_service InvalidService
Is there anything I can do to fix this, as I cannot debug it on my device at the moment?
EDIT: Never mind. I forgot to try simply rebooting my iPod - I had restarted Xcode, and then my Mac, but did not think to reboot my iPod!
Never mind. I forgot to try simply rebooting my iPod - I had restarted Xcode, and then my Mac, but did not think to reboot my iPod!

App is Crashing on iPod Touch First and Second Generation

My released app (Hidden London - Free App) has been reported as crashing on iPod touch 2nd and 3rd Generation. It works without issue on iPhone and iPad.
The crash log is as follows:
Wed Apr 13 09:03:40 unknown kernel[0] <Debug>: launchd[908] Builtin profile: container (sandbox)
Wed Apr 13 09:03:40 unknown kernel[0] <Debug>: launchd[908] Container: /private/var/mobile/Applications/E509FC07-A742-4483-95B1-7393B3F129B9 [69] (sandbox)
Wed Apr 13 09:03:40 unknown sandboxd[911] <Notice>: HiddenLondon(908) deny file-write-data /private/var/mobile/Applications/E509FC07-A742-4483-95B1-7393B3F129B9/HiddenLondon.app/HiddenLondon.sqlite
Wed Apr 13 09:03:40 unknown HiddenLondon[908] <Warning>: Not purchased: com.Beutelkind.HiddenLondon.ExtraPlaces
Wed Apr 13 09:03:40 unknown HiddenLondon[908] <Warning>: Not purchased: com.Beutelkind.HiddenLondon.RemoveAds
Wed Apr 13 09:03:42 unknown securityd[910] <Error>: OCSPResponse: now + maxAge > latestNextUpdate, using latestNextUpdate
Wed Apr 13 09:03:42 unknown com.apple.SpringBoard[24] <Notice>: CoreAnimation: timed out fence 500
Wed Apr 13 09:04:00 unknown HiddenLondon[908] <Warning>: ADBannerView: WARNING A banner view (0x159470) has an ad but may be obscured. This message is only printed once per banner view.
Wed Apr 13 09:04:31 unknown configd[22] <Notice>: jetsam: kernel memory event (90), free: 323, active: 1250, inactive: 1494, purgeable: 0, wired: 7841
Wed Apr 13 09:04:31 unknown configd[22] <Notice>: jetsam: kernel termination snapshot being created
Wed Apr 13 09:04:31 unknown com.apple.launchd[1] <Notice>: (UIKitApplication:com.apple.AdSheetPhone[0xabc0]) Exited: Killed
Wed Apr 13 09:04:31 unknown com.apple.launchd[1] <Notice>: (UIKitApplication:com.Beutelkind.HiddenLondon[0x2fef]) Exited: Killed
Wed Apr 13 09:04:31 unknown SpringBoard[24] <Warning>: Received memory warning. Level=1
Wed Apr 13 09:04:31 unknown com.apple.launchd[1] <Notice>: (UIKitApplication:com.apple.mobilemail[0x736e]) Exited: Killed
Wed Apr 13 09:04:31 unknown SpringBoard[24] <Warning>: Received memory warning. Level=1
Wed Apr 13 09:04:32 unknown SpringBoard[24] <Warning>: Application 'AdSheet' exited abnormally with signal 9: Killed
Wed Apr 13 09:04:32 unknown SpringBoard[24] <Warning>: Application 'HiddenLondon' exited abnormally with signal 9: Killed
Wed Apr 13 09:04:32 unknown SpringBoard[24] <Warning>: Application 'Mail' exited abnormally with signal 9: Killed
Wed Apr 13 09:04:32 unknown SpringBoard[24] <Warning>: Memory level is not normal (56%). Delaying auto-relaunch of 'Mail' for 30 seconds.
Wed Apr 13 09:04:32 unknown SpringBoard[24] <Warning>: Received memory warning. Level=1
Wed Apr 13 09:04:33 unknown ReportCrash[917] <Error>: Saved crashreport to /Library/Logs/CrashReporter/LowMemory-2011-04-13-090433.plist using uid: 0 gid: 0, synthetic_euid: 0 egid: 0
Could anyone help me start to troubleshoot why this might be happening on the iPod Touch?
The hint to why your app is crashing is Received memory warning. Level=1. You're out of memory. This could be the amount of RAM your app is using for data structures, but I've more typically seen this type of error when you run out of graphics memory - i.e. the memory used to composite views, cache images, etc. The total amount of RAM on gen 1 and 2 iPod touches is only 128MB. Gen 3 and 4 bumped that to 256MB.
The memory related info in your log starts with jetsam: kernel memory event (90), free: 323, active: 1250, inactive: 1494, purgeable: 0, wired: 7841, which is a "low memory" warning message. You then see a whole bunch of apps being terminated by the OS (Exited: Killed and exited abnormally with signal 9: Killed). This is the documented behaviour of iOS in low memory conditions - it kills apps until it has enough free memory.
I believe that your application is using a lot of memory, and as a result it gets killed by the operating system.

Error on installation on iPhone, iPod devices "Application exited abnormally with signal 11: Segmentation fault"

I tried to install my application on the devices by using Build and Run from xCode, the application works fine, but when I quit, in the springboard there's no icon for the application, I found the following log on the device's console (which I takes from the Organizer application)
Wed Oct 20 17:05:48 iPod-01 com.apple.launchd[1] (UIKitApplication:com.company.app[0x4cbb][1689]) <Notice>: (UIKitApplication:com.company.app[0x4cbb]) Bug: launchd_core_logic.c:3252 (24226):3
Wed Oct 20 17:05:48 iPod-01 com.apple.launchd[1] (UIKitApplication:com.company.app[0x4cbb][1689]) <Notice>: (UIKitApplication:com.company.app[0x4cbb]) Bug: launchd_core_logic.c:2681 (24226):10
Wed Oct 20 17:05:48 iPod-01 com.apple.launchd[1] (UIKitApplication:com.company.app[0x4cbb][1689]) <Notice>: (UIKitApplication:com.company.app[0x4cbb]) Working around 5020256. Assuming the job crashed.
Wed Oct 20 17:05:48 iPod-01 com.apple.launchd[1] (UIKitApplication:com.company.app[0x4cbb][1689]) <Warning>: (UIKitApplication:com.company.app[0x4cbb]) Job appears to have crashed: Segmentation fault
Wed Oct 20 17:05:48 iPod-01 com.apple.debugserver-48[1688] <Warning>: 1 [0698/1403]: error: ::read ( 4, 0x3809f4, 1024 ) => -1 err = Bad file descriptor (0x00000009)
Wed Oct 20 17:05:48 iPod-01 SpringBoard[27] <Warning>: Application 'AppPlus' exited abnormally with signal 11: Segmentation fault
On the simulator, there's no error at all. Someone has any thought about the issue?

iPhone universal app. MoviePlayer.framwork problem

I have application based on 3.0 iPhone OS SDK
One of tasks is playing video (I use MPMoviePlayerController for this task)
Now I try to make universal app working on both 3.0 and 3.2 OS
I did all steps described in apple documentation: Upgrade Current Target for iPad; make run-time checking for symbols using
[[UIDevice currentDevice] respondsToSelector:#selector(userInterfaceIdiom)]
function. But when I start my application on device - iPhone with OS 3.1.3 my apllication is crashes with next log:
Tue May 25 18:00:28 unknown SpringBoard[24] <Notice>: MultitouchHID(208b30) uilock state: 1 -> 0
Tue May 25 18:00:29 unknown SpringBoard[24] <Notice>: MultitouchHID(292580) device bootloaded
Tue May 25 18:00:34 unknown UIKitApplication:...[0xaa0f][1517] <Notice>: dyld: Symbol not found: _MPMoviePlayerWillEnterFullscreenNotification
Tue May 25 18:00:34 unknown UIKitApplication:...[0xaa0f][1517] <Notice>: Referenced from: /var/mobile/Applications/876EA35E-5756-436B-A9E2-5481D4D62050/....app/...
Tue May 25 18:00:34 unknown UIKitApplication:...[0xaa0f][1517] <Notice>: Expected in: /System/Library/Frameworks/MediaPlayer.framework/MediaPlayer
Tue May 25 18:00:35 unknown kernel[0] <Debug>: launchd[1517] Builtin profile: container (seatbelt)
Tue May 25 18:00:35 unknown kernel[0] <Debug>: launchd[1517] Container: /private/var/mobile/Applications/876EA35E-5756-436B-A9E2-5481D4D62050 (seatbelt)
Tue May 25 18:00:35 unknown ReportCrash[1518] <Notice>: Formulating crash report for process cnetmobile[1517]
Tue May 25 18:00:36 unknown com.apple.launchd[1] <Warning>: (UIKitApplication:...[0xaa0f]) Job appears to have crashed: Trace/BPT trap
Tue May 25 18:00:36 unknown com.apple.launchd[1] <Warning>: (UIKitApplication:...[0xaa0f]) Throttling respawn: Will start in 2147483646 seconds
Tue May 25 18:00:36 unknown SpringBoard[24] <Warning>: Application '...' exited abnormally with signal 5: Trace/BPT trap
Tue May 25 18:00:36 unknown ReportCrash[1518] <Error>: Saved crashreport to /var/mobile/Library/Logs/CrashReporter/..._2010-05-25-180034_...-iPhone.plist using uid: 0 gid: 0, synthetic_euid: 501 egid: 0
Tue May 25 18:01:36 unknown SpringBoard[24] <Notice>: MultitouchHID(208b30) uilock state: 0 -> 1
As you can see the error is "Symbol not found: _MPMoviePlayerWillEnterFullscreenNotification". This symbol is notification available in MediaPlayer.framework starting from iPhone OS 3.2
So, what am I doing wrong? What I should do to have universal application working correct on OS 3.2 (with new available functionality) and older OSes (with their functionality)?
The content of that constant is the string #"MPMoviePlayerWillEnterFullscreenNotification", so you can use this string in place of the constant.
Alternatively, you could
use functions like dlsym to get the symbol at runtime; or
make that symbol weakly linked (= doing step 1 automatically)
It's MediaPlay.framework not added.