summary refs log tree commit diff
path: root/src/trap.c
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/trap.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/trap.c b/src/trap.c
index bbff81a..eae6186 100644
--- a/src/trap.c
+++ b/src/trap.c
@@ -295,7 +295,6 @@ dotrap(void)
 	char *q;
 	int i;
 	int savestatus;
-	int skip = 0;
 
 	savestatus = exitstatus;
 	pendingsigs = 0;
@@ -309,13 +308,13 @@ dotrap(void)
 		p = trap[i + 1];
 		if (!p)
 			continue;
-		skip = evalstring(p, SKIPEVAL);
+		evalstring(p, SKIPEVAL);
 		exitstatus = savestatus;
-		if (skip)
-			break;
+		if (evalskip)
+			return evalskip;
 	}
 
-	return skip;
+	return 0;
 }