about summary refs log tree commit diff
path: root/Src/Builtins/sched.c
diff options
context:
space:
mode:
Diffstat (limited to 'Src/Builtins/sched.c')
-rw-r--r--Src/Builtins/sched.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/Src/Builtins/sched.c b/Src/Builtins/sched.c
index b6b00dff3..8a26b47f3 100644
--- a/Src/Builtins/sched.c
+++ b/Src/Builtins/sched.c
@@ -78,8 +78,11 @@ schedaddtimed(time_t t)
 static void
 scheddeltimed(void)
 {
-    deltimedfn(checksched);
-    schedcmdtimed = 0;
+    if (schedcmdtimed)
+    {
+	deltimedfn(checksched);
+	schedcmdtimed = 0;
+    }
 }