Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 28 Oct 2020 22:13:47 +0000
From:      bugzilla-noreply@freebsd.org
To:        bugs@FreeBSD.org
Subject:   [Bug 250701] [tty] [patch] Race condition between tty_wait_background() and doenterpgrp()
Message-ID:  <bug-250701-227-ynjeTfESKk@https.bugs.freebsd.org/bugzilla/>
In-Reply-To: <bug-250701-227@https.bugs.freebsd.org/bugzilla/>
References:  <bug-250701-227@https.bugs.freebsd.org/bugzilla/>

next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D250701

--- Comment #1 from commit-hook@FreeBSD.org ---
A commit references this bug:

Author: kib
Date: Wed Oct 28 22:12:47 UTC 2020
New revision: 367120
URL: https://svnweb.freebsd.org/changeset/base/367120

Log:
  Check for process group change in tty_wait_background().

  The calling process's process group can change between PROC_UNLOCK(p)
  and PGRP_LOCK(pg) in tty_wait_background(), e.g. by a setpgid() call
  from another process. If that happens, the signal is not sent to the
  calling process, even if the prior checks determine that one should be
  sent.  Re-check that the process group hasn't changed after acquiring
  the pgrp lock, and if it has, redo the checks.

  PR:   250701
  Submitted by: Jakub Piecuch <j.piecuch96@gmail.com>
  MFC after:    2 weeks

Changes:
  head/sys/kern/tty.c

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-250701-227-ynjeTfESKk>