Re: trap and exit status
From: Michael Wang (mwang_at_unixlabplus.com)
Date: 07/29/03
- Next message: Laurent Vogel: "Re: how long does it take"
- Previous message: scriptOmatic: "Re: how long does it take"
- In reply to: scriptOmatic: "Re: trap and exit status"
- Next in thread: Ben: "Re: trap and exit status"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Tue, 29 Jul 2003 17:43:07 GMT
In article <3F26AACE.9E221D42@ChironComputing.Com>,
scriptOmatic <ScriptOmatic@OpenSysMon.Com> wrote:
>Michael Wang wrote:
>>
>> I wonder if there is a solution in ksh (88 or 93) for following spec:
>>
>> - setup exit and signal trap
>> - retain the exit status as if no trap was set (exit status-128 or 256 is ok)
>> - differentiate exit and signal trap, as they will perform different tasks
>>
>> Thanks.
>> --
>> Michael Wang * http://www.unixlabplus.com/ * mwang@unixlabplus.com
>
>see the file "new" at ftp.opensysmon.com/pub/scripts/new.*
>there is a zip file
SIGINT=2
trap "Exit ${SIGINT};" ${SIGHUP} ${SIGINT} ${SIGTERM}
did not satisfy the spec "retain the exit status as if no trap was set".
-- Michael Wang * http://www.unixlabplus.com/ * mwang@unixlabplus.com
- Next message: Laurent Vogel: "Re: how long does it take"
- Previous message: scriptOmatic: "Re: how long does it take"
- In reply to: scriptOmatic: "Re: trap and exit status"
- Next in thread: Ben: "Re: trap and exit status"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|
|