From: Phil Pennock <comet@fysh.org>
To: Zsh users list <zsh-users@sunsite.auc.dk>
Subject: Re: .zlogout RE: Problem w/ ulimit killing compiles on sol 2.4&2.6 ...
Date: Thu, 4 Feb 1999 18:38:57 +0000 [thread overview]
Message-ID: <19990204183857.A7590@fysh.org> (raw)
Typing away merrily, Peter Stephenson produced the immortal words:
> > For those who really want maintenance logs or whatever, but still want
> > to exec something (an interruptible secure program), I usually suggest a
> > function/alias that does a TRAPEXIT/trap '' 0 -- is this really the
> > best idea?
>
> The exit trap isn't run before an exec, for just the same reason that
> .zlogout isn't, i.e. the shell isn't exiting, it's overlaying a
> process without forking first. I should think the only thing you can
> do is hook into exec itself by an alias or function. But the securer
> you want to be, the better it probably is just to call whatever
> explicitly before the exec. Unless you're saying something slightly
> different to what I've understood.
I think I am. I meant:
function exit_and_foo {
function TRAPEXIT { exec foo }
exit
}
defined and then just call exit_and_foo.
--
--> Phil Pennock ; GAT d- s+:+ a23 C++(++++) UL++++/I+++/S+++/B++/H+$ P++@$
L+++ E-@ W(+) N>++ o !K w--- O>+ M V !PS PE Y+ PGP+ t-- 5++ X+ R !tv b++>+++
DI+ D+ G+ e+ h* r y?
next reply other threads:[~1999-02-04 18:38 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
1999-02-04 18:38 Phil Pennock [this message]
-- strict thread matches above, loose matches on Subject: below --
1999-02-04 15:34 Bart Schaefer
1999-02-04 15:21 Peter Stephenson
1999-02-04 14:30 Phil Pennock
1999-02-04 13:52 Andrej Borsenkow
1999-02-04 13:47 Peter Stephenson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=19990204183857.A7590@fysh.org \
--to=comet@fysh.org \
--cc=zsh-users@sunsite.auc.dk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).