IOS Crash Log Analysis (iii)

Source: Internet
Author: User
Tags uikit

If you don't know how to get Crashlog or Crash log symbology see these two articles

How to get the real machine crash Log file

How to symbolize crash log files

Opening crash Log will see the following information:

Incident IDENTIFIER:AF4F2C83-8F68-47EF-B5AA-F16B067B5DF4
Crashreporter key:5670de85ee1f0f3c904891536e81ec086ed4b35b
Hardware model:iphone8,1
Process:kidneyuser [896]
Path:/private/var/containers/bundle/application/48c71aa1-eb99-49b1-abd7-2903dba8e394/kidneyuser.app/kidney User
Identifier:kidneydiseasehospitaluser
Version:1 (1.0)
Code type:arm-64 (Native)
Parent Process:launchd [1]

date/time:2016-05-05 10:45:43.43 +0800
Launch time:2016-05-05 10:42:07.07 +0800
OS Version:ios 9.3.1 (13E238)
Report version:105

Exception Type:exc_crash (SIGABRT)
Exception codes:0x0000000000000000, 0x0000000000000000
Exception note:exc_corpse_notify
Triggered by thread:0

Filtered syslog:
None found

Last Exception BackTrace:
0 corefoundation 0x181aeee38 __exceptionpreprocess + 124
1 LIBOBJC. A.dylib 0x181153f80 Objc_exception_throw + 56
2 CoreData 0x18393ab44-[nsmanagedobjectmodel Initwithcontentsofurl:] + 856
3 Kidneyuser 0x1002b81d8 0x1000d8000 + 1966552
4 Kidneyuser 0x1002b82dc 0x1000d8000 + 1966812
5 Kidneyuser 0x1002b86a0 0x1000d8000 + 1967776
6 Kidneyuser 0x1002b87cc 0x1000d8000 + 1968076
7 Kidneyuser 0x1002b8024 0x1000d8000 + 1966116
8 UIKit 0x186cc9128-[uiapplication _terminatewithstatus:] + 280
9 UIKit 0x186ee7f08 __102-[uiapplication _handleapplicationdeactivationwithscene:shouldforce exit:transitioncontext:completion:]_block_invoke2017 + 796
Ten UIKit 0x186eeafd8 _runaftercacommitdeferredblocks + 292
UIKit 0x186ef8990 _cleanupaftercaflushandrundeferredblocks + 92
UIKit 0X186C2A4A4 _aftercacommithandler + 96
Corefoundation 0x181aa47b0 __cfrunloop_is_calling_out_to_an_observer_callback_function__ + 32
Corefoundation 0x181aa2554 __cfrunloopdoobservers + 372
Corefoundation 0x181aa2984 __cfrunlooprun + 928
Corefoundation 0X1819CCD10 cfrunlooprunspecific + 384
Graphicsservices 0x1832b4088 Gseventrunmodal + 180
UIKit 0x186ca1f70 Uiapplicationmain + 204
Kidneyuser 0x1002c71e8 0x1000d8000 + 2028008
Libdyld.dylib 0X18156A8B8 start + 4


Global Trace Buffer (reverse chronological seconds):
2.434148 applejpeg 0x000000018354ea88 [0x12e203600] releasing session



Thread 0 Name:dispatch Queue:com.apple.main-thread
Thread 0 Crashed:
0 libsystem_kernel.dylib 0x000000018168811c __pthread_kill + 8
1 libsystem_pthread.dylib 0x0000000181754ef8 Pthread_kill + 112
2 libsystem_c.dylib 0x00000001815f9dac abort + 140
3 libc++abi.dylib 0x000000018112d3f4 __cxa_bad_cast + 0
4 libc++abi.dylib 0x0000000181149e98 Default_unexpected_handler () + 0
5 LIBOBJC. A.dylib 0x0000000181154248 _objc_terminate () + 124
6 libc++abi.dylib 0x0000000181146f44 std::__terminate (void (*) ()) + 16
7 Libc++abi.dylib 0X0000000181146B10 __cxa_rethrow + 144
8 LIBOBJC. A.dylib 0x0000000181154120 Objc_exception_rethrow + 44
9 corefoundation 0x00000001819ccdb8 cfrunlooprunspecific + 552
Ten graphicsservices 0x00000001832b4088 Gseventrunmodal + 180
UIKit 0x0000000186ca1f70 Uiapplicationmain + 204
Kidneyuser 0x00000001002c71e8 0x1000d8000 + 2028008

Libdyld.dylib 0X000000018156A8B8 start + 4

The above is the crash Log file information (device information, crash information, exception information, thread information)

1. Device Information

Incident IDENTIFIER:AF4F2C83-8F68-47EF-B5AA-F16B067B5DF4//ID of Crash
Crashreporter key:5670de85ee1f0f3c904891536e81ec086ed4b35b//Crash Device ID
Hardware model:iphone8,1//Phone model (iphone8,1 for iphone6s 8, 2 for iphone6s Plus)
Process:kidneyuser [896]//App name (process ID of the app)
Path:/private/var/containers/bundle/application/48c71aa1-eb99-49b1-abd7-2903dba8e394/kidneyuser.app/kidney User//location path of the APP
Identifier:kidneydiseasehospitaluser//Bundle ID
Version:1 (1.0)//version number of the app
Code type:arm-64 (Native)//App architecture for apps
Parent Process:launchd [1]

date/time:2016-05-05 10:45:43.43 +0800//Crash time of occurrence
Launch time:2016-05-05 10:42:07.07 +0800//Enter the application time
OS Version:ios 9.3.1 (13E238)//version of iOS system
Report version:105

If the product on-line, back to collect a large number of crash log file, can be crash file inside the phone model, version number, phone model, iOS system version, classification, you can get more information, better solve the bug and even the specific cause of the bug, do better testing

2. Exception information

Exception Type:exc_crash (SIGABRT) //type of exception
Exception codes:0x0000000000000000, 0x0000000000000000 //Abnormal error code
Exception note:exc_corpse_notify //Exception notification
Triggered by thread:0 //exception occurred thread (0 for main thread, others for main thread)

Supplement common exception codes code types

Exception Codes: Common code has the following kinds of
0X8BADF00D Error Code:watchdog timed out, meaning "ate bad food".
0XDEADFA11 Error Code:user forced to quit, meaning "dead fall".
0xbaaaaaad Error Code:the user presses the home and volume keys to get the current memory status and does not represent a crash.
0xbad22222 Error Code:VoIP applications (because too often?) ) was killed by iOS.
0XC00010FF Error Code:because it is too hot to be killed, meaning "cool off."
0xdead10cc Error Code:because in the background still occupy system resources (such as Communication Records) was killed, meaning "dead lock"

Supplemental information for common exception type exception types:

1.exc_bad_access: This type is the most common crash, typically used to access memory that should not be accessed, and the general Exc_bad_access () will have additional information

SIGSEGV: usually due to repeated release of objects, generally rarely seen after arc

SIGABRT: received abort signal exit, usually foundtion in the library in order to protect the status of normal will do some detection, such as inserting nil to the data medium will encounter such errors.

SEGV (Segmentation violation): represents an invalid memory address, such as a null pointer, uninitialized pointer, stack overflow, and so on.

Sigbus: Total Stack error, unlike SIGSEGV, SIGSEGV accesses an invalid address, while Sigbus accesses a valid address, but the total stack access exception (such as address alignment issues)

Sigill: attempt to execute an illegal instruction that may not be recognized or has no permissions

SIGFPE: mathematical calculations related to problems, such as 0 operations

sigipipe: No process at the other end of the pipeline takes over data

2. Exc_bad_instruction: This type of exception is usually caused by a thread executing an illegal instruction
3. Exc_arithmetic: except for 0 errors, this type of exception is thrown

Last Exception BackTrace: The final anomaly backtracking, generally according to this code can find specific crash problems

The following intercept is the Yes Crash blog

Thread 0 Name:dispatch Queue:com.apple.main-thread
Thread 0:
0 libsystem_kernel.dylib 0x000000018223ff24 __psynch_cvwait + 8
1 libsystem_pthread.dylib 0x000000018230ad20 _pthread_cond_wait + 704
2 Foundation 0x0000000182f9fdf0-[nscondition waituntildate:] + 344
3 Foundation 0x0000000182f9ce34-[nsconditionlock lockwhencondition:beforedate:] + 256
4 UIKit 0x000000018781dbc4-[uikeyboardtaskqueue waituntilalltasksarefinished] + 196
5 UIKit 0x0000000187c05878-[uikeyboardimpl setkeyboardinputmode:userinitiated:] + 112
6 UIKit 0x0000000187c0de44-[uikeyboardimpl recomputeactiveinputmodeswithextensions:] + 336
7 UIKit 0x000000018781e8f0-[uikeyboardimpl Setdelegate:force:] + 2292
8 UIKit 0x0000000187817eb0-[uiperipheralhost (uikitinternal) _reloadinputviewsforresponder:] + 1180
9 UIKit 0x00000001878179e4-[uiresponder (uiresponderinputviewadditions) reloadinputviews] + 80
Ten UIKit 0x0000000187879670-[uiresponder Becomefirstresponder] + 600
UIKit 0x0000000187879a1c-[uiview (Hierarchy) Becomefirstresponder] + 148
UIKit 0x0000000187900b34-[uitextfield Becomefirstresponder] + 64
UIKit 0x00000001879b1fe4-[uitextinteractionassistant (uitextinteractionassistant_internal) Setfirstresponderifnecessary] + 256
UIKit 0x00000001879b1498-

We can see the crash call stack of the thread that occurred crash, from top to bottom represent the order of the call, the top one represents the place to throw the exception, and one at a time to see the API call Order , the information indicates that this crash appears in the [ Nscondition Waituntildate:] In this method (the value I guess is the address offset O (∩_∩) o) can probably find the specific reason for crash (a method in a file), so the problem surfaced, so that the product on-line version of the iteration, Modify the bug.


Finally, there is a great God analysis of the great God analysis crash Log very detailed

IOS Crash Log Analysis (iii)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.