使用 Titanum Mobile for iPhone 开发的应用程序随机崩溃
我使用 Appcelerator 的 Titanum Mobile 开发了一款 iPhone 应用程序,我已经遇到崩溃和内存泄漏有一段时间了...值得庆幸的是,崩溃很少发生,因此,尽管如此,我的应用程序仍然可用。
然而,现在我已经开始使用 iPhone 4S 和 iOS 5.0.1 测试我的应用程序,随机崩溃现在发生得更加频繁,而且没有明显的原因。
我收到报告称,有时我的应用程序会在短时间内反复崩溃,有时会平稳运行一个多小时,然后再次崩溃。
有没有人也经历过类似的事情?
注意:我使用的是 Titanium Mobile 1.7.5。
I've developed an iPhone app using the Titanum Mobile from Appcelerator, and I've been experiencing crashes and memory leaks for some time now... Thankfully the crashes only happened rarely, so that, despite them, my app was still usable.
However now that I have begun testing my app with iPhone 4S and iOS 5.0.1, the random crashes are now happening much more frequently for no apparent reason.
I have had reports that sometimes my app crashes repeatedly in a short amount of time and that sometime later it runs smoothly for over an hour and then crashes again.
Has anyone also experienced something similar?
Note: I am using the Titanium Mobile 1.7.5.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
原因:内存不足。尽管 Titanium 应该为您处理内存管理,但它并不总是正常工作。大多数时候,特别是如果您的应用程序很简单并且不使用很多图像和动画,Titanium 随着时间的推移产生的内存泄漏将足够小,您甚至不会意识到您的应用程序实际上正在泄漏。问题是,当您的应用程序达到一定程度的复杂性时,这些泄漏就会变得明显——以突然的、不可避免的崩溃的形式出现。
要解决这个问题,您应该尝试从这里开始 - http://developer.appcelerator.com/question/116867/this-is-a-solution-to-your-memory-woes
The reason : memory starvation. Although Titanium is supposed to take care of memory management for you, it doesn’t always work correctly. Most of the times, especially if your application is simple and doesn’t use many images and animations, the memory leaks Titanium generates over time will be small enough that you won’t even realise that your application is actually leaking. Problem is, when your application reaches a certain level of complexity, those leaks will become evident – in the form of sudden, unavoidable crashes.
to resolve you should try something from here - http://developer.appcelerator.com/question/116867/this-is-a-solution-to-your-memory-woes