LogoopenSUSE Build Service > Projects
Sign Up | Log In

View File java-1.7.0-openjdk-java-access-bridge-tck.patch of Package java-1_7_0-openjdk (Project openSUSE:Factory:ARM)

--- java-access-bridge-1.22.0/bridge/org/GNOME/Accessibility/JavaBridge.java.orig	2008-05-22 11:27:00.000000000 -0400
+++ java-access-bridge-1.22.0/bridge/org/GNOME/Accessibility/JavaBridge.java	2008-05-22 11:28:02.000000000 -0400
@@ -34,6 +34,9 @@
 import javax.accessibility.AccessibleRole;
 import javax.accessibility.AccessibleText;
 import javax.accessibility.AccessibleEditableText;
+import java.security.PrivilegedAction;
+import java.security.AccessController;
+
 
 public class JavaBridge {
 
@@ -332,7 +335,11 @@
 			System.err.println ("Java Accessibility Bridge for GNOME loaded.\n");
 
 		// Not sure what kind of arguments should be sent to ORB
-		String vm_rev = System.getProperty("java.version");
+		String vm_rev = (String) AccessController.doPrivileged(new PrivilegedAction() {
+			public java.lang.Object run() {
+				return System.getProperty("java.version");
+			}
+		});	
 
 		if (vm_rev.compareTo("1.4.0") < 0) {
 			System.err.println("WARNING: Java Accessibility Bridge " +