< prev index next >
src/hotspot/share/prims/jvm.cpp
Print this page
@@ -2972,11 +2972,11 @@
if (millis < 0) {
THROW_MSG(vmSymbols::java_lang_IllegalArgumentException(), "timeout value is negative");
}
- if (Thread::is_interrupted (THREAD, true) && !HAS_PENDING_EXCEPTION) {
+ if (thread->is_interrupted(true) && !HAS_PENDING_EXCEPTION) {
THROW_MSG(vmSymbols::java_lang_InterruptedException(), "sleep interrupted");
}
// Save current thread state and restore it at the end of this block.
// And set new thread state to SLEEPING.
@@ -3069,11 +3069,11 @@
ThreadsListHandle tlh(thread);
JavaThread* receiver = NULL;
bool is_alive = tlh.cv_internal_thread_to_JavaThread(jthread, &receiver, NULL);
if (is_alive) {
// jthread refers to a live JavaThread.
- Thread::interrupt(receiver);
+ receiver->interrupt();
}
JVM_END
JVM_ENTRY(jboolean, JVM_IsInterrupted(JNIEnv* env, jobject jthread, jboolean clear_interrupted))
@@ -3082,11 +3082,11 @@
ThreadsListHandle tlh(thread);
JavaThread* receiver = NULL;
bool is_alive = tlh.cv_internal_thread_to_JavaThread(jthread, &receiver, NULL);
if (is_alive) {
// jthread refers to a live JavaThread.
- return (jboolean) Thread::is_interrupted(receiver, clear_interrupted != 0);
+ return (jboolean) receiver->is_interrupted(clear_interrupted != 0);
} else {
return JNI_FALSE;
}
JVM_END
< prev index next >