Skip to content

Commit

Permalink
Treat "aborting" status as alive, as in MRI.
Browse files Browse the repository at this point in the history
MRI appears to only consider a thread dead when its status is
THREAD_KILLED, which is set during the final thread cleanup. In
our checking if the native thread is still alive should be enough.
headius committed Jan 9, 2018
1 parent 2148feb commit 048632e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/src/main/java/org/jruby/RubyThread.java
Original file line number Diff line number Diff line change
@@ -920,7 +920,7 @@ public final Map<Object, IRubyObject> getContextVariables() {
}

public boolean isAlive(){
return threadImpl.isAlive() && status.get() != Status.ABORTING;
return threadImpl.isAlive();
}

@JRubyMethod(name = "[]", required = 1)

0 comments on commit 048632e

Please sign in to comment.