Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Getting information about dead processes
- X-seq: zsh-workers 41395
- From: Leah Neukirchen <leah@xxxxxxxx>
- To: zsh-workers@xxxxxxx
- Subject: Re: Getting information about dead processes
- Date: Tue, 04 Jul 2017 16:01:38 +0200
- In-reply-to: <20170704123913.15d5d06f__26986.931943293$1499168455$gmane$org@pwslap01u.europe.root.pri> (Peter Stephenson's message of "Tue, 04 Jul 2017 12:39:13 +0100")
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- References: <CGME20170704112709epcas4p4b1ccfc1885203983ec5d0a3288de4560@epcas4p4.samsung.com> <87bmp0tqjd.fsf@gmail.com> <20170704123913.15d5d06f__26986.931943293$1499168455$gmane$org@pwslap01u.europe.root.pri>
Peter Stephenson <p.stephenson@xxxxxxxxxxx> writes:
> On Tue, 4 Jul 2017 13:00:54 +0200
> Leah Neukirchen <leah@xxxxxxxx> wrote:
>> in $? or $status we can find the exit code of the last process, but I
>> can't see a way to find more detail about the exit status. The job
>> layer has access to WIFSIGNALED and WTERMSIG, and displays if a
>> process died due to a signal. How can I access this data from a zsh
>> script/interactive session?
>
> If the process died due to a signal, then 128 is added to the signal
> value. So 130 indicates a process died to to signal 2, almost certainly
> SIGINT. The status value itself would be irrelevant, as the process
> didn't get the chance to return one.
Yes, but that is not distinguishable from a process just returning 141
or something else above 128.
--
Leah Neukirchen <leah@xxxxxxxx> http://leah.zone
Messages sorted by:
Reverse Date,
Date,
Thread,
Author