JohnBurley has asked for the wisdom of the Perl Monks concerning the following question:
I would like to intercept Ctrl-S/Ctrl-Q from STDIN, so I can pass them on to child processes.
I wrote a simple test program to attached routines to all the signals available so as to explore if a signal was available. But it seems Ctrl-S/Ctrl-Q is trapped before it gets to STDIN.
For the parent process, the normal flow control works just fine with output, Ctrl-S stops the output flow and the program, and Ctrl-Q resumes the output.
My main requirement is having the ability for a parent process to temporary halt a child process. The old fashion XOFF/XON or Ctrl-S/Ctrl-Q seems the natural choice, plus its built-in, if I can detect the chars to send to the child process.
Thanks for any help.
PS. This is on Windows
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: How to intercept ctrl-S/ctrl-Q characters from STDIN
by BrowserUk (Patriarch) on Aug 20, 2008 at 21:55 UTC | |
by JohnBurley (Initiate) on Aug 22, 2008 at 18:51 UTC | |
by Mr. Muskrat (Canon) on Aug 21, 2008 at 17:41 UTC | |
by BrowserUk (Patriarch) on Aug 21, 2008 at 17:55 UTC | |
by Mr. Muskrat (Canon) on Aug 22, 2008 at 14:56 UTC | |
by BrowserUk (Patriarch) on Aug 22, 2008 at 15:14 UTC | |
|
Re: How to intercept ctrl-S/ctrl-Q characters from STDIN
by FunkyMonk (Bishop) on Aug 20, 2008 at 21:31 UTC |