Issue #7503 has been updated by kosaki (Motohiro KOSAKI).

Status changed from Closed to Assigned

> Target version changed from 2.0.0 to next minor

r38216 was reverted then.
 

----------------------------------------
Feature #7503: make timeout.rb async-interrupt safe by default
https://bugs.ruby-lang.org/issues/7503#change-34508

Author: kosaki (Motohiro KOSAKI)
Status: Assigned
Priority: Normal
Assignee: matz (Yukihiro Matsumoto)
Category: core
Target version: next minor


Hi

Again and again we discussed, current timeout.rb is very dangerous because ExitException interrupt argument code and unwind call stack immediately.
It may prevent to run ensure block and makes resource leak.

I proposed change default to interrupted only on blocking point.

patch is here.
https://gist.github.com/4195015

I also propse to add 'immediate' optional argument because it may help to make a workaround timeout.rb + zero blocking point corner case.

What do you think?


-- 
http://bugs.ruby-lang.org/