How can I fix this SIGABRT error with my app?

10,119

Solution 1

If this is happening on the simulator, restart your computer. If this is happening on a real device, restart the device, and if the problem persists, restart the computer as well. This problem has occurred for me multiple times, because of a zombified process left on the device/simulator when a test is unexpectedly aborted. A simple reboot will fix it.

Solution 2

All your code gets run through the main.m. So what you really want to see is a stack trace and there's is a good example here, but I see you're using the autoreleasepool so you'll need something like

//
//  main.m
//  MyCard
//
//  Created by Nazar Gren on 2/2/12.
//  Copyright (c) 2012 Nazar Gren. All rights reserved.
//

#import <UIKit/UIKit.h>

#import "mycardAppDelegate.h"

int main(int argc, char *argv[])
{
     @autoreleasepool {
        @try {
            return UIApplicationMain(argc, argv, nil, NSStringFromClass([mycardAppDelegate class]));
        } @catch (NSException *e) {
            NSLog(@"CRASH: %@", e);
            NSLog(@"Stack Trace: %@", [e callStackSymbols]);
        }
     }
 }

Solution 3

This is not in Main code. Can be anywhere. Please try zombie tool in instruments. You are probably trying to access an object which has been already released. NSZombie will tell you which is the object and you can investigate from there.

Solution 4

Did you remove a reference to something attached in your main storyboard?

If so, checkout the referencing outlets of that object to see if it's still trying to point to something, try removing that reference and running your simulator again...

Share:
10,119
user1186514
Author by

user1186514

Updated on June 04, 2022

Comments

  • user1186514
    user1186514 almost 2 years

    I am currently developing an app in Xcode 4 for the IPhone and I have com across this error, "Thread 1: Program Received Signal: SIGABRT", This error is in my main.m code.

    //
    //  main.m
    //  MyCard
    //
    //  Created by Nazar Gren on 2/2/12.
    //  Copyright (c) 2012 Nazar Gren. All rights reserved.
    //
    
    #import <UIKit/UIKit.h>
    
    #import "mycardAppDelegate.h"
    
    int main(int argc, char *argv[])
    {
         @autoreleasepool {
            return UIApplicationMain(argc, argv, nil, NSStringFromClass([mycardAppDelegate         class]));
         }
     }
    

    My error appears on the line under the @autorelease pool line. In the debugger, I get this message, "This generally means that another instance of this process was already running or is hung in the debugger." And this error only occurs when I attempt to debug my app. My app doesn't even run. Can anyone help? It would be greatly appreciated.