Project

General

Profile

Actions

Feature #7503

open

make timeout.rb async-interrupt safe by default

Added by kosaki (Motohiro KOSAKI) almost 9 years ago. Updated over 3 years ago.

Status:
Assigned
Priority:
Normal
Target version:
-
[ruby-core:50524]

Description

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?

Actions

Also available in: Atom PDF