我在Xcode 5中开发了一个应用程序。到目前为止,我只在运行iOS 7的设备上测试过它。我尝试在iOS 6的另一台设备上运行它,但它在主函数中启动时崩溃,而控制台中没有任何错误消息。部署目标是6.0,我在构建设置中选择了标准体系结构(armv7,armv7s)。
我还检查了代码中仅适用于iOS 7的方法。可能是我不小心跳过了一个吗?至于我知道如果它不能识别该方法我应该收到错误信息。
我不是iOS开发的新手,但有些东西正在引起我的注意。你知道它可能是什么吗?
我真的很感谢你的帮助。谢谢。
更新:
这就是......它可能是在plist中的东西......?
由于“OC Rickard”,我终于找到了问题的根源。在控制台中写'bt',这是输出:
CFDictionaryRemoveValue + 12, queue = 'com.apple.main-thread, stop reason = EXC_BAD_ACCESS (code=1, address=0x0)
frame #0: 0x38a8b454 CoreFoundation
CFDictionaryRemoveValue + 12
帧#1:0x36e58e28 GraphicsServices RemoveFont + 740
frame #2: 0x36e58868 GraphicsServices
AddFontsFromCGFontAndPath + 332
帧#3:0x36e58660 GraphicsServices AddFontsFromURLOrPath + 156
frame #4: 0x36e59e12 GraphicsServices
Initialize_block_invoke_0 + 378
第5帧:0x36e3a4b6 libdispatch.dylib _dispatch_client_callout + 22
frame #6: 0x36e403f6 libdispatch.dylib
dispatch_once_f $ VARIANT $ mp + 42
帧#7:0x36e57f7a GraphicsServices Initialize + 78
frame #8: 0x36e57fc0 GraphicsServices
GSFontCreateWithName + 56
帧#9:0x31c7cfea UIKit UINewFont + 58
frame #10: 0x31c7cf9a UIKit
+ [UIFont systemFontOfSize:traits:] + 18
帧#11:0x31fa608c UIKit -[UIStatusBarServiceItemView _contentsImageFromString:withWidth:letterSpacing:forStyle:] + 124
frame #12: 0x31cd888a UIKit
- [UIStatusBarServiceItemView _serviceContentsImageForStyle:] + 362
帧#13:0x31cd84ac UIKit -[UIStatusBarServiceItemView updateContentsAndWidth] + 140
frame #14: 0x31cd823e UIKit
- [UIStatusBarItemView initWithItem:data:actions:style:] + 306
帧#15:0x31cd7f90 UIKit -[UIStatusBarLayoutManager _createViewForItem:withData:actions:] + 108
frame #16: 0x31c877de UIKit
- [UIStatusBarLayoutManager _prepareEnabledItemType:withEnabledItems:withData:actions:itemAppearing:itemDisappearing:] + 134
帧#17:0x31c8770e UIKit -[UIStatusBarLayoutManager prepareEnabledItems:withData:actions:] + 82
frame #18: 0x31f9e910 UIKit
- [UIStatusBarForegroundView _setStatusBarData:actions:animated:] + 168
帧#19:0x31c87662 UIKit -[UIStatusBarForegroundView setStatusBarData:actions:animated:] + 722
frame #20: 0x31cd7516 UIKit
- [UIStatusBar _prepareToSetStyle:animation:] + 794
帧#21:0x31c8978e UIKit -[UIStatusBar requestStyle:animationParameters:] + 558
frame #22: 0x31c894a8 UIKit
- [UIStatusBar requestStyle:animated:] + 84
帧#23:0x31cd2f6e UIKit -[UIApplication _createStatusBarWithRequestedStyle:orientation:hidden:] + 258
frame #24: 0x31cd2736 UIKit
- [UIApplication _runWithURL:payload:launchOrientation:statusBarStyle:statusBarHidden:] + 430
帧#25:0x31c7ac38 UIKit -[UIApplication handleEvent:withNewEvent:] + 1004
frame #26: 0x31c7a6cc UIKit
- [UIApplication sendEvent:] + 72
帧#27:0x31c7a11a UIKit _UIApplicationHandleEvent + 6154
frame #28: 0x36e5d5a2 GraphicsServices
_ PurpleEventCallback + 590
帧#29:0x36e5d1d2 GraphicsServices PurpleEventCallback + 34
frame #30: 0x38b1d172 CoreFoundation
__ CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION + 34
帧#31:0x38b1d116 CoreFoundation __CFRunLoopDoSource1 + 138
frame #32: 0x38b1bf98 CoreFoundation
__ CFRunLoopRun + 1384
帧#33:0x38a8eebc CoreFoundation CFRunLoopRunSpecific + 356
frame #34: 0x38a8ed48 CoreFoundation
CFRunLoopRunInMode + 104
帧#35:0x31cd147c UIKit -[UIApplication _run] + 668
frame #36: 0x31cce2f8 UIKit
UIApplicationMain + 1120
帧#37:0x00085f96 iSpyLove main(argc=1, argv=0x2fd98d20) + 110 at main.m:16
frame #38: 0x362fab20 libdyld.dylib
开始+ 4 我在plist文件中声明了一个扩展名为.dfont的字体。显然iOS 6不喜欢这个。谢谢你“OC Rickard”,感谢你们所有人对我的问题感兴趣。