[Gambas-devel] Unused signals to be sent
Benoît Minisini
gambas at ...1...
Sun May 6 23:51:10 CEST 2012
Le 06/05/2012 21:36, tobi a écrit :
> Hi,
>
> I know that at least SIGUSR1 is needed by gbx3 or something to abort the current program.
Where did you see that? :-o
The SIGUSR1 is handled by a debugged program, so that the IDE can tell
him that the users has pressed the PAUSE button so that it stops on the
next line.
> I am
> currently implementing an interface to the terminal driver to enable no-delay keyboard input. The
> experiences of my research were several manual reset button hits because the keyboard was screwed
> up when not properly cleaned up, which I didn't find nice and my computer neither - and of course
> I learned all that I need to implement that _correctly_ ;). Now, the cleanup works great whenever:
> * the program exits
> * an error occurs
> * the user hits ESC thrice during one second (emergency exit) (this enabled, however all users to
> screw up the program logic as it immediately exits the mode, the programmer chose for the
> application. But better than hardware reset if the program is misbehaving. I have to think about
> that...)
>
Are terminal programs run in an X11 terminual emulator concerned too?
> I additionally, not only for consistency issues, want to be able to switch between virtual consoles
> when in this NoDelay mode. In another program I saw that the authors used signals they taught the vt
> driver to sent the program when a switch was requested from another vt to the one that program runs
> in and in the current vt, they take that under direct control of the program. Not that difficult
> but I need signals to be sent. What signal may I use? (The program I mentioned above uses SIGUSR1
> and SIGUSR2 (for release and acquire) and I am not able to use these in Gambas, right? So which
> one are sure to use?)
I don't understand what you are talking about. If you want to *send*
signal, no problem. Difficulty comes when you want to receive them.
>
> (And, Benoît, wasn't there once the approach to register signal handlers using the interpreter API?
> I still need that to enable the terminal Resize event)
Here is the point: to receive signals reliably, you need a bunch of code
that I want the interpreter to provide to the components through API.
I didn't write this API yet, because it is more complex than I thought
first. If you want more details, look at the "signalfd" system call that
can solve most of my problems, but that is alas Linux specific, so I
prefer not to use it!
Regards,
--
Benoît Minisini
More information about the Devel
mailing list