Tue, 11 Mar 2014 14:01:16 -0700
Merge
.hgtags | file | annotate | diff | comparison | revisions |
1.1 --- a/.hgtags Wed Feb 26 22:06:37 2014 -0800 1.2 +++ b/.hgtags Tue Mar 11 14:01:16 2014 -0700 1.3 @@ -251,6 +251,9 @@ 1.4 b8c71dae05574f8eca7ca6d703b16b450850b033 jdk8-b127 1.5 113e7569b49bca18846e5e5b74e644580b805902 jdk8-b128 1.6 5c72d74c6805d1b4f6192f7a3550d126acf37005 jdk8-b129 1.7 +0683ee308085785d0455f4153e764e062843f178 jdk8-b130 1.8 +5e5c8f0c45dd75a08089586ca50835393f00c2cb jdk8-b131 1.9 +84fed37bbe640666bfc022c2e8b9fde468de35d2 jdk8-b132 1.10 5de8d42f9eb7ddcdc741445f3c21a63887d694b6 jdk8u5-b01 1.11 c750098a3ef18de28a6d739666559f0333c76c78 jdk8u5-b02 1.12 3d9b40a53134aa33031bf13581dff9fccade9048 jdk8u5-b03 1.13 @@ -262,3 +265,5 @@ 1.14 df6e5fc3b585a6829c98bb91546b81dc28f8e2b4 jdk8u5-b08 1.15 f5058197fa91153b7702214154d37b00f9714aaa jdk8u5-b09 1.16 d9031b5525f777299554080d6beb8b077df0a614 jdk8u5-b10 1.17 +a2f7b36bfc1bc8df033fe5721b48fac1c3928a5b jdk8u5-b11 1.18 +475b96f6d8cecf720ca9fd6d332dd4bafb0f654c jdk8u5-b12
2.1 --- a/src/share/classes/com/sun/corba/se/spi/orb/ORB.java Wed Feb 26 22:06:37 2014 -0800 2.2 +++ b/src/share/classes/com/sun/corba/se/spi/orb/ORB.java Tue Mar 11 14:01:16 2014 -0700 2.3 @@ -1,5 +1,5 @@ 2.4 /* 2.5 - * Copyright (c) 2002, 2013, Oracle and/or its affiliates. All rights reserved. 2.6 + * Copyright (c) 2002, 2014, Oracle and/or its affiliates. All rights reserved. 2.7 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 2.8 * 2.9 * This code is free software; you can redistribute it and/or modify it 2.10 @@ -170,6 +170,12 @@ 2.11 // representing LogDomain and ExceptionGroup. 2.12 private Map wrapperMap ; 2.13 2.14 + static class Holder { 2.15 + static final PresentationManager defaultPresentationManager = 2.16 + setupPresentationManager(); 2.17 + } 2.18 + private static final Object pmLock = new Object(); 2.19 + 2.20 private static Map staticWrapperMap = new ConcurrentHashMap(); 2.21 2.22 protected MonitoringManager monitoringManager; 2.23 @@ -235,13 +241,24 @@ 2.24 */ 2.25 public static PresentationManager getPresentationManager() 2.26 { 2.27 - AppContext ac = AppContext.getAppContext(); 2.28 - PresentationManager pm = (PresentationManager) ac.get(PresentationManager.class); 2.29 - if (pm == null) { 2.30 - pm = setupPresentationManager(); 2.31 - ac.put(PresentationManager.class, pm); 2.32 + SecurityManager sm = System.getSecurityManager(); 2.33 + if (sm != null && AppContext.getAppContexts().size() > 0) { 2.34 + AppContext ac = AppContext.getAppContext(); 2.35 + if (ac != null) { 2.36 + synchronized (pmLock) { 2.37 + PresentationManager pm = 2.38 + (PresentationManager) ac.get(PresentationManager.class); 2.39 + if (pm == null) { 2.40 + pm = setupPresentationManager(); 2.41 + ac.put(PresentationManager.class, pm); 2.42 + } 2.43 + return pm; 2.44 + } 2.45 + } 2.46 } 2.47 - return pm; 2.48 + 2.49 + // No security manager or AppContext 2.50 + return Holder.defaultPresentationManager; 2.51 } 2.52 2.53 /** Get the appropriate StubFactoryFactory. This