in reply to (crazyinsomniac) Re: Re: keyboard input during runtime...
in thread keyboard input during runtime...

*laughs* If you just comment out the else-section where you call theloopy(), then you run just fine. :)

I suspect the problem you had is that you were calling theloopy() from within the SIG{INT} handler. I tried doing a goto out, but something still keeps track that you're within the handling of a SIG{INT}, thus (I suspect) preventing the handling of another SIG{INT}. (Of course, that's pure speculation.)

The reason why if you just let the SIG{INT} handler end if you don't want to do anything works just fine is that the handler will return back to where it was invoked from if nothing is done. I've used that to good use in other applications.

------
/me wants to be the brightest bulb in the chandelier!

  • Comment on Re: (crazyinsomniac) Re: Re: keyboard input during runtime...