8165064: Enhance thread contexts in JNDI
authorvinnie
Thu, 13 Oct 2016 15:27:33 +0100
changeset 41585 8da39dd19c93
parent 41584 80eb0a13864f
child 41586 d6f36cdf633c
8165064: Enhance thread contexts in JNDI Reviewed-by: chegar
jdk/src/java.base/share/classes/java/lang/Thread.java
--- a/jdk/src/java.base/share/classes/java/lang/Thread.java	Wed Oct 12 13:53:41 2016 -0400
+++ b/jdk/src/java.base/share/classes/java/lang/Thread.java	Thu Oct 13 15:27:33 2016 +0100
@@ -504,11 +504,12 @@
     }
 
     /**
-     * Creates a new Thread that inherits the given AccessControlContext.
+     * Creates a new Thread that inherits the given AccessControlContext
+     * but thread-local variables are not inherited.
      * This is not a public constructor.
      */
     Thread(Runnable target, AccessControlContext acc) {
-        init(null, target, "Thread-" + nextThreadNum(), 0, acc, true);
+        init(null, target, "Thread-" + nextThreadNum(), 0, acc, false);
     }
 
     /**