changeset 5610:58602549247e

8007611: logging behavior in applet changed Reviewed-by: alanb, jgish
author mchung
date Thu, 07 Feb 2013 09:41:47 -0800
parents 10bf0ec57a6e
children 068448362d88
files src/share/classes/java/util/logging/LogManager.java
diffstat 1 files changed, 4 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/share/classes/java/util/logging/LogManager.java	Tue Feb 05 22:56:47 2013 -0800
+++ b/src/share/classes/java/util/logging/LogManager.java	Thu Feb 07 09:41:47 2013 -0800
@@ -363,7 +363,10 @@
                         context = userContext;
                     } else {
                         context = new LoggerContext();
-                        context.addLocalLogger(manager.rootLogger);
+                        // during initialization, rootLogger is null when
+                        // instantiating itself RootLogger
+                        if (manager.rootLogger != null)
+                            context.addLocalLogger(manager.rootLogger);
                     }
                     javaAwtAccess.put(ecx, LoggerContext.class, context);
                 }