SDL fullscreen apps & mouse pointer on X11

This problem is present only on X11 and I don’t know if there is an easy

If I run an SDL fullscreen application and that application hangs I can
anyway terminate it with:

killall -9 appname

On a console terminal (that I can open with CTRL + ALT + F1) or from a
remote ssh session.

The problem is that if I have to terminate the application with -9 when I go
back to the X11 display the mouse pointer is struck.

The workaround to fix it is to run another (or the same) SDL application
that opens a fullscreen window, hides the pointer and then exits in a clean

Here is a concept test program, I use a real program to do this normally so
this is untested:

int main()
SDL_SetVideoMode(640, 480, 0, SDL_FULLSCREEN);

Then I’m able again to move the mouse pointer, obviously I can also do CTRL

  • ALT + BACKSPACE, but that closes also all the open applications and
    terminals so the first solution is better. There is anyway that can be done
    at SDL level to prevent this kind of situations? I know there is
    SDL_INIT_PARACHUTE, but it cannot work with kill -9…–
    Ing. Gabriele Greco, DARTS Engineering
    Tel: +39-0105761240 Fax: +39-0105760224
    s-mail: Via G.T. Invrea 14 - 16129 GENOVA (ITALY)