Nested threading? implications to timeout()

E

Eric Hodel

This still leaves the race problem.

Where did I say this fixed any race conditions?
If you can raise an exception between an ensure and its first
instruction,

This appears to be impossible in the current interpreter.
NOTHING can be safe in the ensure clause.

If the first node is begin, then you appear to be safe. See my
response to the first message in this thread.
To solve this problem would require some changes to the language
semantics. At the very least external exceptions should not be
accepted when inside an ensure clause. This would require some
interpreter changes and certainly more thougth than what I have given
it.

Threads are switched after returning from rb_eval, not before. The
first node inside an ensure will always be executed. Your thread may
be switched after you begin to return from rb_eval.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Members online

No members online now.

Forum statistics

Threads
473,770
Messages
2,569,583
Members
45,075
Latest member
MakersCBDBloodSupport

Latest Threads

Top