summaryrefslogtreecommitdiff
path: root/lib/timeout.rb
diff options
context:
space:
mode:
authorNobuyoshi Nakada <[email protected]>2022-05-25 18:47:16 +0900
committergit <[email protected]>2022-05-25 18:47:26 +0900
commite77e233935007c418acdcac13de0e76e3b514fb0 (patch)
tree93f3bf778e3e17582ffc91fe848ecc5c18cbb33c /lib/timeout.rb
parentcdfb0272131ed8ef078d371556c2cad40b31d2fb (diff)
[ruby/timeout] Hack to avoid leak checker
https://github.com/ruby/timeout/commit/9a9b03b44c
Diffstat (limited to 'lib/timeout.rb')
-rw-r--r--lib/timeout.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/timeout.rb b/lib/timeout.rb
index 996df6e859..24ffccb0da 100644
--- a/lib/timeout.rb
+++ b/lib/timeout.rb
@@ -99,6 +99,7 @@ module Timeout
def self.create_timeout_thread
Thread.new do
+ Thread.current.thread_variable_set(:"\0__detached_thread__", true)
requests = []
while true
until QUEUE.empty? and !requests.empty? # wait to have at least one request