From 3c274c2bbc792815e1142df30c1b3c285bfd5e4d Mon Sep 17 00:00:00 2001 From: Koichi Murase Date: Wed, 10 Feb 2021 17:37:02 +0900 Subject: [PATCH 1/2] clean up fg dead jobs in trap (Option 1) --- jobs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/jobs.c b/jobs.c index 2c91fb0e..278aac12 100644 --- a/jobs.c +++ b/jobs.c @@ -1226,7 +1226,7 @@ cleanup_dead_jobs () if (i > js.j_lastj && jobs[i]) INTERNAL_DEBUG(("cleanup_dead_jobs: job %d non-null after js.j_lastj (%d)", i, js.j_lastj)); - if (jobs[i] && DEADJOB (i) && IS_NOTIFIED (i)) + if (jobs[i] && DEADJOB (i) && (IS_NOTIFIED (i) || IS_FOREGROUND (i))) delete_job (i, 0); } -- 2.36.1