View | Details | Raw Unified | Return to bug 250701
Collapse All | Expand All

(-)b/sys/kern/tty.c (+11 lines)
Lines 474-479 tty_wait_background(struct tty *tp, struct thread *td, int sig) Link Here
474
			sig = 0;
474
			sig = 0;
475
		}
475
		}
476
		PGRP_LOCK(pg);
476
		PGRP_LOCK(pg);
477
		/*
478
		 * pg may no longer be our process group.
479
		 * Run the checks again if that's the case.
480
		 */
481
		PROC_LOCK(p);
482
		if (__predict_false(p->p_pgrp != pg)) {
483
			PROC_UNLOCK(p);
484
			PGRP_UNLOCK(pg);
485
			continue;
486
		}
487
		PROC_UNLOCK(p);
477
		pgsignal(pg, ksi.ksi_signo, 1, &ksi);
488
		pgsignal(pg, ksi.ksi_signo, 1, &ksi);
478
		PGRP_UNLOCK(pg);
489
		PGRP_UNLOCK(pg);
479
490

Return to bug 250701