开发者

Getting Exception SIGKILL when relaunching app

I build and run a project in iPhone simulator. I send it to background by pressing the home button. Then I double press the home button to find my app in the background and tap it. It becomes active and the app continues to run. Here I got no problem no matter how many times I repeat this. Then I kill the process by tapping the little red minus sign on the app's icon. But if I again tap the app icon to relaunch it I get SIGKILL error and app crashes. What could be the开发者_如何学Go reason for this? Could it be caused by my XCode preferences?


This isn't really a crash: It's just XCode having a delayed reaction to your tapping the little red minus sign. When you terminate your app this way, the operating system sends a SIGKILL signal to your process – but XCode's debugger doesn't "see" the SIGKILL until after you relaunch the app.

You can "recover" from this "crash" by hitting the Continue button in the debugger, incidentally.


I've seen similar crashes in the simulator when I didn't let the debugger detach itself gracefully from the app. Rather than killing the app by tapping the little red minus sign, try hitting the "stop" button in Xcode.

To further confirm that this is related to the debugger, try running the app the first time by tapping on the icon rather than using Build and Run in Xcode. Then kill it by tapping on the red X and relaunch it. If it still crashes without the debugger attached, then my hypothesis is invalid.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜