summary refs log tree commit diff
path: root/Src
diff options
context:
space:
mode:
Diffstat (limited to 'Src')
-rw-r--r--Src/builtin.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/Src/builtin.c b/Src/builtin.c
index 70de5bcec..85c961e3d 100644
--- a/Src/builtin.c
+++ b/Src/builtin.c
@@ -4434,6 +4434,7 @@ zexit(int val, int from_where)
 #endif
 	}
     }
+    lastval = val;
     if (sigtrapped[SIGEXIT])
 	dotrap(SIGEXIT);
     callhookfunc("zshexit", NULL, 1);