diff options
author | nagachika <nagachika@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2019-08-03 12:27:02 +0000 |
---|---|---|
committer | nagachika <nagachika@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2019-08-03 12:27:02 +0000 |
commit | 194a55259bc5d58b48c00f01030b460072aa7fd3 (patch) | |
tree | a8660169418c62752fbb2c6a047c59ecdc2da6eb /probes_helper.h | |
parent | adbb1c699d730431f0152cd5836231bb83e0014a (diff) |
merge revision(s) 1ef39d8d099f145222b9352423af16a2bab6e05b: [Backport #15798]
Fix process not waking up on signals on OpenBSD
When using UBF_TIMER_PTHREAD (the UBF handler on OpenBSD), the
timer_pthread_fn function will not signal the main thread with
SIGVTALRM in cases where timer_pthread is armed before
consume_communication_pipe is called. This is because
consume_communication_pipe will unarm the timer.
Fix this by checking the return value of consume_communication_pipe.
If it returns TRUE and the timer_pthread is disarmed, then signal
the main thread with SIGVTALRM.
On OpenBSD, this fixes TestThread#test_thread_timer_and_interrupt, and
fixes hangs in TestProcess#test_execopts_redirect_open_fifo_interrupt_raise
and TestProcess#test_execopts_redirect_open_fifo_interrupt_print.
It also fixes the use of Ctrl+C/SIGINT in irb on OpenBSD. It does not
cause any test failures on Linux when UBF_TIMER_PTHREAD is forced as
the UBF handler.
Fixes [Bug #15798]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_6@67725 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'probes_helper.h')
0 files changed, 0 insertions, 0 deletions