7172522: Improve DomainCombiner checking
authormullan
Mon, 18 Jun 2012 10:00:55 -0400
changeset 14208 fd8e875982e9
parent 14207 7d6689d7e260
child 14209 221f6d0a12ea
7172522: Improve DomainCombiner checking Reviewed-by: vinnie, ahgross
jdk/src/share/classes/java/security/AccessController.java
--- a/jdk/src/share/classes/java/security/AccessController.java	Fri Jun 15 09:51:09 2012 +0800
+++ b/jdk/src/share/classes/java/security/AccessController.java	Mon Jun 18 10:00:55 2012 -0400
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1997, 2011, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -293,7 +293,7 @@
         DomainCombiner dc = null;
         AccessControlContext acc = getStackAccessControlContext();
         if (acc == null || (dc = acc.getAssignedCombiner()) == null) {
-            return AccessController.doPrivileged(action);
+            return AccessController.doPrivileged(action, acc);
         }
         return AccessController.doPrivileged(action, preserveCombiner(dc));
     }
@@ -389,7 +389,7 @@
         DomainCombiner dc = null;
         AccessControlContext acc = getStackAccessControlContext();
         if (acc == null || (dc = acc.getAssignedCombiner()) == null) {
-            return AccessController.doPrivileged(action);
+            return AccessController.doPrivileged(action, acc);
         }
         return AccessController.doPrivileged(action, preserveCombiner(dc));
     }