willow
willow

Reputation: 301

new problem in xcode 4

When we open a new project in xcode and then run that, this will run without any error. but if we close the application in simulator ( by duble click on the home button and keeping MouseButton on the applicaton and hitting the red circle) and click on the desired application icon again, this makes an error in the following link

 int retVal = UIApplicationMain(argc, argv, nil, nil);

what's problem ?

Upvotes: 1

Views: 98

Answers (1)

chown
chown

Reputation: 52728

Your manually terminating the process in the simulator, so the debugging session ends when you terminate the App, probably by the simulated OS sending a SIG_KILL to the process, which gets cought and rethrown by another routine within the main run loop. Thats why it shows up in gdb.


Edit:

To attach to a process manually (for checking if everything in the applicationWillTerminate method executed properly, etc):

What you can do is run your App in the simulator, click 'Stop' in xCode or click 'X' on the App in the Simulator task list to close the App. Then run it in the Simulator manually by clicking the App icon in the simulator, and once it is open use Xcode to attach to the new process (by name or process ID) from the 'Product' -> 'Attach to Process' menu (Xcode 4.1).

Upvotes: 3

Related Questions