crash文件分析

使用symbolicatecrash分析

通过命令find /Applications/Xcode.app -name symbolicatecrash -type f
找到真机的symbolicatecrash, 然后通过设置环境变量,这样就可以全局访问。

/Applications/Xcode.app/Contents/Developer/Platforms/WatchSimulator.platform/Developer/Library/PrivateFrameworks/DVTFoundation.framework/symbolicatecrash
/Applications/Xcode.app/Contents/Developer/Platforms/AppleTVSimulator.platform/Developer/Library/PrivateFrameworks/DVTFoundation.framework/symbolicatecrash
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/PrivateFrameworks/DVTFoundation.framework/symbolicatecrash // 模拟器
/Applications/Xcode.app/Contents/SharedFrameworks/DVTFoundation.framework/Versions/A/Resources/symbolicatecrash   // 真机

分析文件

将xx.crash和xx.dSYM文件放在一个文件里,然后通过命令解析

symbolicatecrash *.crash  *.dSYM > crash.log

如果遇到Error: "DEVELOPER_DIR" is not defined at /Applications/Xcode.app/Contents/SharedFrameworks/DVTFoundation.framework/Versions/A/Resources//symbolicatecrash line 69.
需要配置

export DEVELOPER_DIR=/Applications/Xcode.app/Contents/Developer

问题类型

1.访问越界

Exception Type:  EXC_BAD_ACCESS (SIGABRT)
Exception Subtype: KERN_INVALID_ADDRESS at 0x2000000011deb438
VM Region Info: 0x2000000011deb438 is not in any region.  Bytes after previous region: 2305842998239212601  
      REGION TYPE                      START - END             [ VSIZE] PRT/MAX SHRMOD  REGION DETAIL
      MALLOC_NANO            0000000280000000-00000002a0000000 [512.0M] rw-/rwx SM=PRV  
--->  
      UNUSED SPACE AT END

你可能感兴趣的:(crash文件分析)