友盟错误日志分析

有一些朋友看到了错误日志,却不知道怎么定位到程序的的代码中,实际上,这一步是非常的简单。
友盟没有集成.dSYM文件,只能显示错误的地址,无法显示详细的信息。


准备步骤,
1,友盟错误日志
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
                 *** -[__NSArrayM objectAtIndex:]: index 20 beyond bounds [0 .. 19]
( null )
(
     "0   CoreFoundation                      0x371308bf __exceptionPreprocess + 162" ,
     "1   libobjc.A.dylib                     0x317fe1e5 objc_exception_throw + 32" ,
     "2   CoreFoundation                      0x37079b6b -[__NSArrayM objectAtIndex:] + 270" ,
     "3   aaaaa                              0x0004af6f aaaaa + 302959" ,
     "4   UIKit                               0x3277d565 -[UITableView _selectRowAtIndexPath:animated:scrollPosition:notifyDelegate:] + 944" ,
     "5   UIKit                               0x327f5ce7 -[UITableView _userSelectRowAtPendingSelectionIndexPath:] + 158" ,
     "6   Foundation                          0x31ba0943 __NSFireDelayedPerform + 414" ,
     "7   CoreFoundation                      0x37104a63 __CFRUNLOOP_IS_CALLING_OUT_TO_A_TIMER_CALLBACK_FUNCTION__ + 14" ,
     "8   CoreFoundation                      0x371046c9 __CFRunLoopDoTimer + 364" ,
     "9   CoreFoundation                      0x3710329f __CFRunLoopRun + 1206" ,
     "10  CoreFoundation                      0x370864dd CFRunLoopRunSpecific + 300" ,
     "11  CoreFoundation                      0x370863a5 CFRunLoopRunInMode + 104" ,
     "12  GraphicsServices                    0x3123cfcd GSEventRunModal + 156" ,
     "13  UIKit                               0x326f8743 UIApplicationMain + 1090" ,
     "14  aaaaa                              0x00003687 aaaaa + 9863" ,
     "15  aaaaa                              0x00003144 aaaaa + 8516"
)

 2.找到.dSYM文件,在编译程序时,会自动生成这个文件,

3.把应用 aaaaaa.app和 .dSYM文件放到一个目录中,

执行

1
atos -arch armv7 -o 'aaaaaa.app/aaaa' -l 0x0004af6f
 这样就得到了程序错误的对应的源代码地址。
--------------------------------------


当然,如果你的程序很复杂,友盟的功能肯定不够使用。


友盟无法返回详细的信息,Binary Images, Thread 0 crashed with ARM Thread State.. 更主要的是,很许多的错误代码友盟无法收集,也无法收集更多的信息。
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值