书上实战1:MobileNotes最后Tweak的编写,安装后MobileNotes总是闪退

如题,代码片段都一模一样,原因是因为我hook了noteContentLayerContentDidChange:updateTitle这个函数,后来发现这个函数就算里面直接%orig。其他任何事情都不做,都会闪退。我得系统式8.1.1的,有没有同学知道这个问题应该怎么解决。

你在syslog里搜“crash”,找到MobileNotes闪退的那一段输出,贴出来看看

Jesse:~ root# cat /var/log/syslog | grep ‘crash’
indent preformatted text by 4 spacesApr 10 15:28:39 Jesse crash_mover[1986]: MS:Notice: Injecting: (null) [crash_mover] (1141.16) Apr 10 15:28:54 Jesse assertiond[58]: Forcing crash report of <BKNewProcess: 0x137e14a20; com.evernote.iPhone.Evernote; pid: 1966; hostpid: -1>... Apr 10 15:28:54 Jesse assertiond[58]: Finished crash reporting. Apr 10 15:35:18 Jesse lockdownd[143]: 00584000 copy_crashcopier_value: copying com.apple.MobileDeviceCrashCopy domain: ShouldSubmit key Apr 10 15:35:18 Jesse crash_mover[2009]: MS:Notice: Injecting: (null) [crash_mover] (1141.16) Apr 10 15:49:07 Jesse ReportCrash[2102]: Formulating crash report for process MobileNotes[2100] Apr 10 15:49:07 Jesse SpringBoard[1452]: Application 'UIKitApplication:com.apple.mobilenotes[0x59ca]' crashed. Apr 10 16:07:11 Jesse ReportCrash[2221]: Formulating crash report for process MobileNotes[2219] Apr 10 16:07:12 Jesse SpringBoard[2154]: Application 'UIKitApplication:com.apple.mobilenotes[0xe10b]' crashed.indent preformatted text by 4 spaces
Jesse:~ root#

问题已解决,自己犯了一个低级错误,结贴。

这还看不出来什么,你直接把syslog文件传上来吧