changeset 13394:c89275e90496

8146038: CleanerImpl should not depend on ManagedLocalsThread Reviewed-by: rriggs
author chegar
date Tue, 22 Dec 2015 21:30:48 +0000
parents 9359b41628d5
children 47e7d7363249
files src/java.base/share/classes/jdk/internal/misc/CleanerImpl.java
diffstat 1 files changed, 2 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/src/java.base/share/classes/jdk/internal/misc/CleanerImpl.java	Tue Dec 22 14:12:55 2015 -0500
+++ b/src/java.base/share/classes/jdk/internal/misc/CleanerImpl.java	Tue Dec 22 21:30:48 2015 +0000
@@ -39,7 +39,6 @@
 import java.util.function.Function;
 
 import sun.misc.InnocuousThread;
-import sun.misc.ManagedLocalsThread;
 
 /**
  * CleanerImpl manages a set of object references and corresponding cleaning actions.
@@ -130,8 +129,8 @@
      */
     public void run() {
         Thread t = Thread.currentThread();
-        ManagedLocalsThread mlThread = (t instanceof ManagedLocalsThread)
-                ? (ManagedLocalsThread) t
+        InnocuousThread mlThread = (t instanceof InnocuousThread)
+                ? (InnocuousThread) t
                 : null;
         while (!phantomCleanableList.isListEmpty() ||
                 !weakCleanableList.isListEmpty() ||
@@ -787,4 +786,3 @@
     }
 
 }
-