Skip to content
This repository has been archived by the owner on May 29, 2024. It is now read-only.

Commit

Permalink
8269934: RunThese24H.java failed with EXCEPTION_ACCESS_VIOLATION in j…
Browse files Browse the repository at this point in the history
…ava_lang_Thread::get_thread_status

Reviewed-by: stuefe, dcubed, sspitsyn
  • Loading branch information
David Holmes authored and tkrodriguez committed Sep 17, 2021
1 parent e887c22 commit c9c667d
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/hotspot/share/services/threadService.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -878,7 +878,10 @@ void ThreadSnapshot::initialize(ThreadsList * t_list, JavaThread* thread) {
_sleep_ticks = stat->sleep_ticks();
_sleep_count = stat->sleep_count();

_thread_status = java_lang_Thread::get_thread_status(threadObj);
// If thread is still attaching then threadObj will be NULL.
_thread_status = threadObj == NULL ? JavaThreadStatus::NEW
: java_lang_Thread::get_thread_status(threadObj);

_is_suspended = thread->is_suspended();
_is_in_native = (thread->thread_state() == _thread_in_native);

Expand Down

0 comments on commit c9c667d

Please sign in to comment.