Ad Hoc仅在设备上构建崩溃 - ASIHTTPRequest [英] Ad Hoc Builds Crashing on Device Only - ASIHTTPRequest

查看:145
本文介绍了Ad Hoc仅在设备上构建崩溃 - ASIHTTPRequest的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

编辑

此问题与ASIHTTPRequest有关。当我删除ASIHTTPRequest异步块时,应用程序不再在我的设备上崩溃。我可以在我的设备上运行ASIHTTPRequest代码,从Xcode中加载。就在我从TestFlight上传档案并尝试运行它崩溃的时候。设备崩溃日志显示:

This problem is related to ASIHTTPRequest. When I remove the ASIHTTPRequest async block, the app does not crash on my device any more. I can run the ASIHTTPRequest code on my device, loaded from Xcode fine. It's just when I upload the archive from TestFlight and try to run it that it crashes. The device crash log shows:

异常类型:EXC_BAD_ACCESS(SIGSEGV)
异常代码:KERN_INVALID_ADDRESS位于0x00000058
崩溃的线程:0

Exception Type: EXC_BAD_ACCESS (SIGSEGV) Exception Codes: KERN_INVALID_ADDRESS at 0x00000058 Crashed Thread: 0

线程0名称:调度队列:com.apple.main-thread
线程0崩溃:

Thread 0 name: Dispatch queue: com.apple.main-thread Thread 0 Crashed:

全部突然,今天,在通过TestFlight上传的20个成功临时构建和运行后,我的最后3个AD Hoc成功上传到TestFlight但在我的测试设备上崩溃。

All of a sudden, today, after 20 successful ad hoc builds and runs uploaded via TestFlight, my last 3 AD Hoc successfully upload to TestFlight but crash on my test device.

这些构建从Xcode上移到设备上时运行得很好。事实上,我可以退出应用程序,断开我的设备与Xcode的连接,应用程序运行良好,就像我说的,我能够使用我的AD Hoc分发配置文件成功将这些构建上传到TestFlight。但是当我去安装并运行时,应用程序会执行启动图像,然后崩溃。

These builds run perfectly when coming off of Xcode onto the device. In fact, i can quit the app, disconnect my device from Xcode and the app runs fine and like I said, I am able to successfully upload those builds to TestFlight with my AD Hoc distribution profile. But when I go to install and run, the app executes up to the launch image and then crashes.

Xcode中的所有设置都保持不变,所以我想知道是否你知道是什么导致了这个吗?

All of the settings in Xcode have remained untouched so I am wondering if you know what could be causing this?

这听起来像我的AD Hoc发布配置文件,因为这是我从TestFlight构建和运行Xcode VS时的唯一区别但奇怪的是它刚停止工作...

It sure sounds like my AD Hoc distribution profile, since that is the only difference between when I build and run from Xcode VS from TestFlight but it's weird that it just stopped working...

其他人有这个问题吗?

我该怎么办?试试下一个?

What should I try next?

推荐答案

我遇到了同样的问题,直接从XCode构建时它完美无缺,但是当通过AD Hoc部署时,它每次都会崩溃。我不知道为什么,但事实证明问题是 ASIHTTPRequest 的完成和失败。以下是我如何解决这个问题。

I had this exact same problem, it worked flawlessly when built directly from XCode but, when deployed through AD Hoc, it'd crash every time. I'm not sure why but as it turns out the problem is with the blocks of ASIHTTPRequest completion and failure. Here is how I worked around it.

ASIHTTPRequest *request = [ASIHTTPRequest requestWithURL:url];
        [request setDidFinishSelector:@selector(completedImg:)];
        [request setDidFailSelector:@selector(failedImg:)];
        [request setDelegate:self];
        [request startAsynchronous];

注意*我在下载视频时只发生了这次崩溃(由于某种原因它可以正常处理文档和图像)。

Note* I only had this crash when downloading videos (it works fine with documents and images for some reason).

这篇关于Ad Hoc仅在设备上构建崩溃 - ASIHTTPRequest的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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