From cb59dfb3a6f6cce414c5b852c138d5f6bea6d563 Mon Sep 17 00:00:00 2001 From: Bart Schaefer Date: Tue, 21 Jun 2022 18:04:45 -0700 Subject: 50379/50380: fix off-by-one side-effect of workers/49906 that broke $(jobs -l) --- Src/jobs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Src/jobs.c') diff --git a/Src/jobs.c b/Src/jobs.c index e0e453ed8..707374297 100644 --- a/Src/jobs.c +++ b/Src/jobs.c @@ -2402,7 +2402,7 @@ bin_fg(char *name, char **argv, Options ops, int func) int curmaxjob, ignorejob; if (unset(MONITOR) && oldmaxjob) { jobptr = oldjobtab; - curmaxjob = oldmaxjob ? oldmaxjob - 1 : 0; + curmaxjob = oldmaxjob; ignorejob = 0; } else { jobptr = jobtab; -- cgit 1.4.1