You can detect whether another process received a signal by ptracing it. If you are only ptracing for signals, then the performance penalty shouldn't be too severe.

Shachar

On 24/11/16 12:35, unDEFER wrote:
On Wednesday, 23 November 2016 at 07:18:27 UTC, Shachar Shemesh wrote:

The shell does that for background processes. I think it takes away
the TTY from its children, and this way, when they try to read from
stdin, they get SIGSTOP from the system.

I'm not sure what the precise mechanism is.

There are flags passed to wait which will cause it to report when a
child gets SIGSTOP.

Hope this helps,
Shachar

So, I have found with strace, this signal is SIGTTIN is special signal
which sends to _background_ task when it tries to read from terminal.

So it is possible such detect when I will write not simple pipeProcess,
but will write terminal emulator.
Thank you.

Reply via email to