更新到Xcode 5.1.1导致iOS应用程序的奇怪崩溃 [英] Updated to Xcode 5.1.1 causes strange crash of iOS app

查看:219
本文介绍了更新到Xcode 5.1.1导致iOS应用程序的奇怪崩溃的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

不幸的是,我自动更新Xcode到版本5.1.1(5B1008),现在我的一个应用程序以非常奇怪的方式崩溃。



PhoneGap 3.4(+ jQuery Mobile 1.3.1)混合应用程序,当我尝试打开一个包含〜20 JQM复选框的JQM页面时,崩溃发生。



崩溃发生在 WebThread 中调用 CoreGraphics CGPathAddLineToPoint 所调用的WebCore WebCore :: RenderThemeIOS :: paintCheckboxDecorations c $ c>,我想当WebCore尝试渲染然后JQM页面上的复选框。



控制台读取:



断言失败:(CGFloatIsValid(x)& amp; CGFloatIsValid(y)),函数void CGPathAddLineToPoint(CGMutablePathRef,const CGAffineTransform *,CGFloat,CGFloat),文件路径/ CGPath.cc,line 224.
(lldb)



任何其他不包含复选框的JQM页面都会正确显示,并且不会导致应用程序崩溃。



$ b

编辑:有趣的是,崩溃是由这行JavaScript触发的:



$('#my_checkbox')。prop(checked,my_boolean_value).checkboxradio(refresh);



,将显示JQM页面。但是,即使上面的行被禁用,如果我点击任何复选框,它再次崩溃,与上面 Assertion失败消息相同。 (我猜测因为JQM切换检查/未检查的类。)



我已经执行了所有的技巧,我可以想到(干净,禁用调试器,重新启动,重新安装Xcode)



有关如何解决这个问题的任何想法?

解决方案

我发现了以下非常刺激的事实:崩溃由

触发

  opacity: .01 

指令,附加到JQM .ui-checkbox class in the CSS。



将其更改为:

  opacity:0 

防止崩溃(我仍然不知道是因为



有趣的是,将任何值设置为大于 0 触发崩溃。


Unfortunately I auto-updated Xcode to Version 5.1.1 (5B1008), and now one of my apps crashes in a very strange way.

The app is a PhoneGap 3.4 (+ jQuery Mobile 1.3.1) hybrid app, the crash happens when I try to open a JQM page that contains ~20 JQM checkbox.

The crash happens in CoreGraphics CGPathAddLineToPoint called by WebCore WebCore::RenderThemeIOS::paintCheckboxDecorations in the WebThread, I guess when WebCore attempts to render the checkboxes on then JQM page.

The console reads:

Assertion failed: (CGFloatIsValid(x) && CGFloatIsValid(y)), function void CGPathAddLineToPoint(CGMutablePathRef, const CGAffineTransform *, CGFloat, CGFloat), file Paths/CGPath.cc, line 224. (lldb)

Any other JQM page NOT containing checkboxes is displayed properly, and it does not crash the app.

EDIT: interestingly, the crash is triggered by this line of Javascript:

$('#my_checkbox').prop("checked", my_boolean_value).checkboxradio("refresh");

If I disable it, the JQM page shows up. But then, even if the above line is disabled, if I click on any checkbox, it crashes again, with the same above Assertion failed message. (I guess because JQM toggles the check/unchecked class.)

I already performed all the tricks I could think of (clean, disable debugger, reboot, reinstalled Xcode), with no luck.

Any ideas on how to solve this issue?

解决方案

I discovered the following very irritating fact: the crash is triggered by a

opacity:.01

directive, attached to the JQM .ui-checkbox class in my CSS.

Changing it to:

opacity:0

prevents the crash (which I still do not know if it is due to an Xcode bug or an iOS bug).

Interestingly, setting any value greater than 0 triggers the crash.

这篇关于更新到Xcode 5.1.1导致iOS应用程序的奇怪崩溃的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆