[Bug 231445] [patch] sleepq_catch_signals will still enter sleep after a ptrace attach event

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Wed May 29 14:06:12 UTC 2019


--- Comment #4 from commit-hook at freebsd.org ---
A commit references this bug:

Author: kib
Date: Wed May 29 14:05:28 UTC 2019
New revision: 348360
URL: https://svnweb.freebsd.org/changeset/base/348360

  Do not go into sleep in sleepq_catch_signals() when SIGSTOP from
  PT_ATTACH was consumed.

  In particular, do not clear TDP_FSTP in ptracestop() if td_wchan is
  non-NULL. Leave it to sleepq_catch_signal() to clear and convert zero
  return code to EINTR.

  Otherwise, per submitter report, if the PT_ATTACH SIGSTOP was
  delivered right after the thread was added to the sleepqueue but not
  yet really sleep, and cursig() caused debugger attach, the thread
  sleeps instead of returning to the userspace boundary with EINTR.

  PR: 231445
  Reported by:  Efi Weiss <valmarelox at gmail.com>
  Reviewed by:  markj
  Sponsored by: The FreeBSD Foundation
  MFC after:    2 weeks
  Differential revision:        https://reviews.freebsd.org/D20381


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

More information about the freebsd-bugs mailing list