IPhone Crash with "No Back Up"

My iPhone app was recently rejected from the App Store because it crashes on launch. However, I cannot reproduce this collapse. The application works great both on the simulator and on the device with the same hardware and software on which Apple tested it (iPhone 3.1 running iOS 4). The crash logs they sent me say "No going back," so I have nothing to look for in my code. Here is an example:

Incident Identifier: [...] CrashReporter Key: [...] Hardware Model: iPhone3,1 Process: [MyApp] [1172] Path: /var/mobile/Applications/[...]-3F1B-4504-A572-[...]/[MyApp].app/[MyApp] Identifier: [MyApp] Version: ??? (???) Code Type: ARM (Native) Parent Process: launchd [1] Date/Time: 2010-07-08 [...] OS Version: iPhone OS 4.0 (8A293) Report Version: 104 Exception Type: EXC_BAD_ACCESS (SIGSEGV) Exception Codes: KERN_INVALID_ADDRESS at 0xfe42c648 Highlighted Thread: 0 Backtrace not available Unknown thread crashed with ARM Thread State: r0: 0x00002388 r1: 0x00000000 r2: 0x3e2b47c8 r3: 0x00000108 r4: 0x2fe00000 r5: 0x00000000 r6: 0x00000000 r7: 0x00000000 r8: 0x2ffffb48 r9: 0x2fffecfc r10: 0x00000000 r11: 0x00000000 ip: 0x00000010 sp: 0x2ffffb4c lr: 0x2fe08907 pc: 0xfe42c648 cpsr: 0x40000010 Binary Images: 0x1000 - 0x78fff +[MyApp] armv7 <23af3d265c3086eaceb51cc649eb794f> /var/mobile/Applications/[...]-3F1B-4504-A572-[...]/[MyApp].app/[MyApp] 0x2fe00000 - 0x2fe26fff dyld armv7 <697ae459733a7f0b6c439b21ba62b110> /usr/lib/dyld [many more libraries...] 

How can I start debugging? Is it possible that this is a build problem and not a coding error? And can I extract any useful information from the “ARM Stream Status” or “Binary Images” parts of the crash report?

Thanks!

* update: * I installed the application for the first time on another iPhone running iOS 4 and still cannot reproduce the crash. I am starting to think that this is a problem with build time parameters such as libraries or target versions. Based on the crash report, is it possible that any code in my application was executed?

+3
source share
4 answers

I could never reproduce the crash. I mixed up several build options and reintroduced and was approved.

0
source

See Technical Note TN2151: Understanding and Analyzing iPhone OS Application Error Reporting. Symbols will usually help you keep track of the source of the failure, but since there is no return, this may not help.

Do not bother with testing on the simulator. Simulator assembly and device assembly are completely separate compilations for two different hardware. Just because it works on a simulator, it says nothing about a failure on the device.

Remember that Apple will test the application by performing actions such as launching it on iOS4, while other applications consume most of the memory. You will need to do this on your test device.

You will likely have to erase the test device back by default in order to play the Apple test. Then open all possible applications before starting your own.

+1
source

You can make some information from the state of the ARM thread. The PC registry is the only one that contains an invalid address that is reported in the crash report. This means that your application has tried to execute code at this address.

SIGSEGV means the specified address is not valid. There are no memory pages with this address in the system.

I don’t think that iOS will allow you to simply execute code from any address, but it is possible that the stack frame was damaged and the return address was invalid when the function returned. This supports the backtrace not available problem.

Stack populations may result from buffer overflows. If you use memcpy or a set loop in a local array of variables and overflow the end of the array, you can destroy the stack.

+1
source

Segfact is unlikely to be a build error. To reproduce this problem, try clearing any stored information on the iPhone simulator before starting the project; it’s possible that you assume that there are certain entries in NSUserDefaults that are present on your own iPhone, but which will not be available by default. If this does not repeat the problem, you should create unit tests for each of your components, excluding each component at a time as the cause of the failure. In the end, you exclude every cause of the failure, except for the true cause of the failure.

0
source

Source: https://habr.com/ru/post/928041/


All Articles