mirror of
https://github.com/corda/corda.git
synced 2025-01-22 12:28:11 +00:00
return false if javaThread is null in Thread::Runnable::interrupted
This field may be null if the thread is in the process of being attached to the VM.
This commit is contained in:
parent
86c48f3ff6
commit
0bbd11e9be
@ -1500,7 +1500,7 @@ class Thread {
|
||||
}
|
||||
|
||||
virtual bool interrupted() {
|
||||
return threadInterrupted(t, t->javaThread);
|
||||
return t->javaThread and threadInterrupted(t, t->javaThread);
|
||||
}
|
||||
|
||||
virtual void setInterrupted(bool v) {
|
||||
@ -2059,10 +2059,10 @@ attachThread(Machine* m, bool daemon)
|
||||
|
||||
addThread(t, t);
|
||||
|
||||
uintptr_t arguments[] = { daemon };
|
||||
|
||||
enter(t, Thread::ActiveState);
|
||||
|
||||
uintptr_t arguments[] = { daemon };
|
||||
|
||||
if (run(t, initAttachedThread, arguments)) {
|
||||
enter(t, Thread::IdleState);
|
||||
return t;
|
||||
|
Loading…
Reference in New Issue
Block a user