线程1:EXC_BAD_ACCESS(代码= 1,地址= 0xf00000c) [英] Thread 1: EXC_BAD_ACCESS (code=1, address=0xf00000c)

查看:127
本文介绍了线程1:EXC_BAD_ACCESS(代码= 1,地址= 0xf00000c)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我遇到线程1的问题:EXC_BAD_ACCESS(代码= 1,地址= 0xf00000c),我不知道如何解决它。
当我在核心日期更改某个对象并保存它并且我尝试将此控制器弹出到父级时出现。
此错误在main()中,带有retVal。
这里是一些代码

I have problem with Thread 1: EXC_BAD_ACCESS (code=1, address=0xf00000c) and I don't know how to resolve it. It appeared when I change some object in core date and save it and I try to pop this controller to parent. This error is in main() with retVal. here is some code

        int retVal;
    @try {
        retVal =  UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class]));
           */\ error is here**
    }
    @catch (NSException *exception) {
        NSLog(@"%@", [exception callStackSymbols]);
        @throw exception;
    }
    return retVal;

重新运行应用程序后,我所有的更改都在核心数据中。更有甚者,这个问题只出现在iOS 7上.iOS 6.1还可以。

After re-runing app all my changes are in core data. What is more this problem is only on iOS 7. iOS 6.1 is ok.

有人知道如何解决它吗?

Does someone have idea how to resolve it?

推荐答案

As评论说这个错误很可能在你的代码中很深。如果罪魁祸首是僵尸,找到它的最简单方法是在探查器中运行它(最好是最新的Xcode,当前Xcode 5,因为它已被改进)并选择Zombies。当它失败时,您可以看到对象发生的所有事件的历史记录。

As a comment said this error is likely to be deep in your code. If the culprit is a zombie, the easiest way to find it is to run it (preferably in the latest Xcode, currently Xcode 5, as it has been improved) in profiler and choose "Zombies". When it fails, you can see the history of everything that has happened to the object.

此外,设置异常断点。当错误发生时你可能会休息,而不是在主要的情况下,异常被传递出去。

Also, set an exception breakpoint. You may get a break when the error happens instead of in main, where the exception gets passed up.

这篇关于线程1:EXC_BAD_ACCESS(代码= 1,地址= 0xf00000c)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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