简体   繁体   English

为什么未通过xcode启动我的iPhone应用程序时崩溃

[英]Why does my iPhone app crash when not launched by xcode

The iPhone app I am developing has a strange quirk where it runs ok when xcode has launched it, but not when launched directly on the device. 我正在开发的iPhone应用程序有一个奇怪的怪癖,它在xcode启动时可以正常运行,但在设备上直接启动时却不能运行。

I've checked the crash logs and the exception seems to be occurring in libxml2.2 in xmlParseCharData. 我已经检查了崩溃日志,并且xmlParseCharData中的libxml2.2中似乎发生了异常。 It's quite a big xml document that is being parsed so I think that might be the problem. 这是一个很大的xml文档,正在被解析,所以我认为这可能是问题所在。

I tried with a smaller xml document and this was fine. 我尝试使用较小的xml文档,这很好。 So either it is the size of the document or something in the document that is causing it but the same large document is parsed ok when launched via xcode. 因此,要么是文档的大小,要么是文档的大小所致,但是当通过xcode启动该大文档时,可以解析相同的大文档。

Any ideas why this would be happening or how I might start trying to debug it? 有什么想法为什么会发生或者如何开始调试呢?

I found the problem. 我发现了问题。 The app was taking too long to start. 该应用启动时间过长。 I eventually noticed in the console log in organizer that this was the problem. 我最终在组织者的控制台日志中注意到这是问题所在。 I changed the app so it has a proper landing screen and it works fine now. 我更改了应用程序,使其具有正确的着陆屏幕,并且现在可以正常工作。

I found a Apple Technical Q&A about this issue. 我找到了有关此问题的苹果技术问答。 http://developer.apple.com/iphone/library/qa/qa2009/qa1592.html http://developer.apple.com/iphone/library/qa/qa2009/qa1592.html

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM