emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: busyloop in sigchld_handler


From: Kim F. Storm
Subject: Re: busyloop in sigchld_handler
Date: Wed, 14 Mar 2007 15:10:28 +0100
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.95 (gnu/linux)

Andreas Schwab <address@hidden> writes:

> address@hidden (Kim F. Storm) writes:
>
>> Andreas Schwab <address@hidden> writes:
>>
>>> address@hidden (Kim F. Storm) writes:
>>>
>>>> Why do we care about stopped processes?
>>>
>>> It is one of the possible states of a process, see process-status.  Any
>>> job control shell need to be able to handle that.
>>
>> Yes, but how does a stopped process cause a sigchld signal to be sent
>> to the parent?
>
> By not using SA_NOCLDSTOP when you register the handler.
>

Ah yes.

But the WUNTRACED flag doesn't mean we don't get info about
stopped processes, it means we also get info about stopped
ptrace'd processes:

                        switch (p->state) {
                        case TASK_STOPPED:
                                if (!p->exit_code)
                                        continue;
                                if (!(options & WUNTRACED) && !(p->ptrace & 
PT_PTRACED))
                                        continue;

But it's not relevant here, I guess.

-- 
Kim F. Storm <address@hidden> http://www.cua.dk





reply via email to

[Prev in Thread] Current Thread [Next in Thread]