< prev index next >

src/java.base/share/classes/sun/nio/ch/Invoker.java

Print this page

        

*** 27,36 **** --- 27,37 ---- import java.nio.channels.*; import java.util.concurrent.*; import java.security.AccessController; import sun.security.action.GetIntegerAction; + import jdk.internal.misc.InnocuousThread; /** * Defines static methods to invoke a completion handler or arbitrary task. */
*** 132,144 **** Thread.interrupted(); // clear thread locals when in default thread pool if (System.getSecurityManager() != null) { Thread me = Thread.currentThread(); ! if (me instanceof sun.misc.InnocuousThread) { GroupAndInvokeCount thisGroupAndInvokeCount = myGroupAndInvokeCount.get(); ! ((sun.misc.InnocuousThread)me).eraseThreadLocals(); if (thisGroupAndInvokeCount != null) { myGroupAndInvokeCount.set(thisGroupAndInvokeCount); } } } --- 133,145 ---- Thread.interrupted(); // clear thread locals when in default thread pool if (System.getSecurityManager() != null) { Thread me = Thread.currentThread(); ! if (me instanceof InnocuousThread) { GroupAndInvokeCount thisGroupAndInvokeCount = myGroupAndInvokeCount.get(); ! ((InnocuousThread)me).eraseThreadLocals(); if (thisGroupAndInvokeCount != null) { myGroupAndInvokeCount.set(thisGroupAndInvokeCount); } } }
< prev index next >