warning message when exiting with active jobs uses PID of first process, not PGID

Work on #4303.
This commit is contained in:
David Adam 2017-10-31 19:17:19 +08:00
parent 9adb3492f9
commit eb081481c6

View File

@ -2163,7 +2163,7 @@ static void bg_job_warning() {
job_iterator_t jobs;
while (job_t *j = jobs.next()) {
if (!job_is_completed(j)) {
fwprintf(stdout, L"%6d %ls\n", j->pgid, j->command_wcstr());
fwprintf(stdout, L"%6d %ls\n", j->processes[0]->pid, j->command_wcstr());
}
}
fputws(L"\n", stdout);