We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 1693 - If the program hangs it's horribly hard to kill it
Summary: If the program hangs it's horribly hard to kill it
Status: RESOLVED INVALID
Alias: None
Product: SDL
Classification: Unclassified
Component: *don't know* (show other bugs)
Version: HG 2.0
Hardware: x86_64 Linux
: P2 normal
Assignee: Ryan C. Gordon
QA Contact: Sam Lantinga
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-01-12 15:29 UTC by Sik
Modified: 2013-01-12 17:42 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Sik 2013-01-12 15:29:21 UTC
Sometimes I screw up the code of my game and end up with an infinite loop. Naturally, the program hangs. The problem is that killing the process can be a chore...

1) If I try to click the close button several times, I don't get any prompt about the program being hung (as usually would happen when it isn't responding to events and such).

2) Then I try to use "killall", but the window still remains on screen for some reason (usually windows would get killed along with the process).

3) Then I try "xkill" and that can kill the window, but the terminal where the program was run from is still stuck (of course Ctrl+C doesn't work), leaving me with no option but to close that terminal tab (which prompts me if I'm sure because a process is still running on it!).

Does anybody know what's up with all this? If the program gets stuck I should be able to kill it without much trouble! I shouldn't need more than #1, in fact (assuming the program has a window for starters).

Using Ubuntu 11.10.
Comment 1 Sam Lantinga 2013-01-12 17:42:15 UTC
Try kill -3
SDL catches other signals and allows the program to gracefully clean up.  This is very important for certain environments where the graphics display will not recover if SDL isn't gracefully shut down.