8146038: CleanerImpl should not depend on ManagedLocalsThread
Reviewed-by: rriggs
--- a/jdk/src/java.base/share/classes/jdk/internal/misc/CleanerImpl.java Tue Dec 22 14:12:55 2015 -0500
+++ b/jdk/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 @@
}
}
-