diff options
Diffstat (limited to 'Src')
-rw-r--r-- | Src/Modules/parameter.c | 15 | ||||
-rw-r--r-- | Src/jobs.c | 4 |
2 files changed, 13 insertions, 6 deletions
diff --git a/Src/Modules/parameter.c b/Src/Modules/parameter.c index df4d1020e..2df362faa 100644 --- a/Src/Modules/parameter.c +++ b/Src/Modules/parameter.c @@ -1222,14 +1222,21 @@ static char * pmjobstate(int job) { Process pn; - char buf[256], buf2[128], *ret, *state; + char buf[256], buf2[128], *ret, *state, *cp; + + if (job == curjob) + cp = ":+"; + else if (job == prevjob) + cp = ":-"; + else + cp = ":"; if (jobtab[job].stat & STAT_DONE) - ret = dupstring("done"); + ret = dyncat("done", cp); else if (jobtab[job].stat & STAT_STOPPED) - ret = dupstring("suspended"); + ret = dyncat("suspended", cp); else - ret = dupstring("running"); + ret = dyncat("running", cp); for (pn = jobtab[job].procs; pn; pn = pn->next) { diff --git a/Src/jobs.c b/Src/jobs.c index ca4b12004..a938e774b 100644 --- a/Src/jobs.c +++ b/Src/jobs.c @@ -43,12 +43,12 @@ mod_export int thisjob; /* the current job (+) */ /**/ -int curjob; +mod_export int curjob; /* the previous job (-) */ /**/ -int prevjob; +mod_export int prevjob; /* the job table */ |