< prev index next >

src/share/vm/utilities/ostream.cpp

Print this page

        

@@ -736,11 +736,11 @@
   if (!should_rotate(force)) {
     return;
   }
 
 #ifdef ASSERT
-  Thread *thread = Thread::current();
+  Thread *thread = Thread::current_or_null();
   assert(thread == NULL ||
          (thread->is_VM_thread() && SafepointSynchronize::is_at_safepoint()),
          "Must be VMThread at safepoint");
 #endif
   if (NumberOfGCLogFiles == 1) {

@@ -1056,12 +1056,12 @@
       writer_id == NO_WRITER ||
 
       // bootstrap problem
       tty_lock == NULL ||
 
-      // can't grab a lock or call Thread::current() if TLS isn't initialized
-      ThreadLocalStorage::thread() == NULL ||
+      // can't grab a lock if current Thread isn't set
+      Thread::current_or_null() == NULL ||
 
       // developer hook
       !SerializeVMOutput ||
 
       // VM already unhealthy
< prev index next >