6814140: deadlock due to synchronized demandLogger() code that locks ServerLogManager
authorpoonam
Wed, 22 Jul 2009 07:49:57 -0700
changeset 3319 53a6d815c92f
parent 3318 dade78e63c92
child 3320 a7c037dd2e14
6814140: deadlock due to synchronized demandLogger() code that locks ServerLogManager Summary: Making demandLogger() non-synchronized resolves the deadlock. Reviewed-by: dcubed
jdk/src/share/classes/java/util/logging/LogManager.java
--- a/jdk/src/share/classes/java/util/logging/LogManager.java	Wed Jul 22 16:41:14 2009 +0800
+++ b/jdk/src/share/classes/java/util/logging/LogManager.java	Wed Jul 22 07:49:57 2009 -0700
@@ -338,7 +338,7 @@
     // already been created with the given name it is returned.
     // Otherwise a new logger instance is created and registered
     // in the LogManager global namespace.
-    synchronized Logger demandLogger(String name) {
+    Logger demandLogger(String name) {
         Logger result = getLogger(name);
         if (result == null) {
             result = new Logger(name, null);