zsh-workers
 help / color / mirror / code / Atom feed
* PATCH: Re: zsh-3.1.9-dev-6 crashes occassionally
@ 2000-11-01  9:33 Sven Wischnowsky
  0 siblings, 0 replies; only message in thread
From: Sven Wischnowsky @ 2000-11-01  9:33 UTC (permalink / raw)
  To: zsh-workers


Bart Schaefer wrote:

> ...
> 
> One other item of note:  For some strange reason, it's not possible to
> alter TRAPxxx functions with "zed -f".  They come up in the editor, and
> if you create one from scratch it sticks, but no changes that you make
> to an already-existing TRAPxxx function are remembered.  No matter how
> you exit zed, they always revert to their previous value.

It's pretty obvious if you look at zed. It calls $cleanup at the end,
which contains the output of `trap'. And hence it resets all trap
functions.

This should fix that. It doesn't fix the bug that one can't edit
TRAPINT and TRAPEXIT (which are used by zed), though. Hm.

Bye
 Sven

Index: Functions/Misc/zed
===================================================================
RCS file: /cvsroot/zsh/zsh/Functions/Misc/zed,v
retrieving revision 1.3
diff -u -r1.3 zed
--- Functions/Misc/zed	2000/07/27 08:14:54	1.3
+++ Functions/Misc/zed	2000/11/01 09:30:00
@@ -55,7 +55,7 @@
     var="$1() {
 }"
   fi
-  vared var && eval function "$var"
+  vared var && eval "$cleanup ;" function "$var"
 else
   [[ -f $1 ]] && var="$(<$1)"
   while vared var

--
Sven Wischnowsky                         wischnow@informatik.hu-berlin.de


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2000-11-01  9:33 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2000-11-01  9:33 PATCH: Re: zsh-3.1.9-dev-6 crashes occassionally Sven Wischnowsky

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).