about summary refs log tree commit diff
path: root/Src
diff options
context:
space:
mode:
authorBart Schaefer <barts@users.sourceforge.net>2000-06-03 16:26:47 +0000
committerBart Schaefer <barts@users.sourceforge.net>2000-06-03 16:26:47 +0000
commit709ce3829cb1c7bfeade8b18b39cd601b9e0decc (patch)
treeea1d8e5c8cbdeae6a869c43eb722a30f9c9cfeab /Src
parent43d443f602422e2d1cb12c1f172c350ef9e781d7 (diff)
downloadzsh-709ce3829cb1c7bfeade8b18b39cd601b9e0decc.tar.gz
zsh-709ce3829cb1c7bfeade8b18b39cd601b9e0decc.tar.xz
zsh-709ce3829cb1c7bfeade8b18b39cd601b9e0decc.zip
11736: Fix TRAPEXIT scoping.
Diffstat (limited to 'Src')
-rw-r--r--Src/signals.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Src/signals.c b/Src/signals.c
index b8e06d444..9b9ef97aa 100644
--- a/Src/signals.c
+++ b/Src/signals.c
@@ -751,7 +751,7 @@ removetrap(int sig)
      * one, to aid in removing this one.  However, if there's
      * already one at the current locallevel we just overwrite it.
      */
-    if (isset(LOCALTRAPS) && locallevel &&
+    if ((isset(LOCALTRAPS) || sig == SIGEXIT) && locallevel &&
 	(!trapped || locallevel > (sigtrapped[sig] >> ZSIG_SHIFT)))
 	dosavetrap(sig, locallevel);