src/hotspot/share/services/management.cpp
changeset 52707 4b427f2653f1
parent 52067 2e72562697bf
child 53103 67e3a8b3449c
child 53504 391d671f222b
--- a/src/hotspot/share/services/management.cpp	Tue Nov 27 21:20:16 2018 -0500
+++ b/src/hotspot/share/services/management.cpp	Tue Nov 27 22:02:52 2018 -0500
@@ -1645,6 +1645,12 @@
     return;
   }
 
+  // NonJavaThread instances may not be fully initialized yet, so we need to
+  // skip any that aren't - check for zero stack_size()
+  if (!thread->is_Java_thread() && thread->stack_size() == 0) {
+    return;
+  }
+
   if (_count >= _names_len || _count >= _times_len) {
     // skip if the result array is not big enough
     return;