From 72a8be591d5daba1e4e231c386812c543d503fce Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Sat, 14 Jan 2023 21:31:45 +0100 Subject: Replace AccessController.doPrivileged() w/ SecurityUtil.doPrivileged() --- src/newt/classes/jogamp/newt/Debug.java | 4 ++-- src/newt/classes/jogamp/newt/NEWTJNILibLoader.java | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) (limited to 'src/newt/classes/jogamp') diff --git a/src/newt/classes/jogamp/newt/Debug.java b/src/newt/classes/jogamp/newt/Debug.java index a255cb755..60b259214 100644 --- a/src/newt/classes/jogamp/newt/Debug.java +++ b/src/newt/classes/jogamp/newt/Debug.java @@ -28,10 +28,10 @@ package jogamp.newt; -import java.security.AccessController; import java.security.PrivilegedAction; import com.jogamp.common.util.PropertyAccess; +import com.jogamp.common.util.SecurityUtil; /** Helper routines for logging and debugging. */ @@ -41,7 +41,7 @@ public class Debug extends PropertyAccess { private static final boolean debugAll; static { - AccessController.doPrivileged(new PrivilegedAction() { + SecurityUtil.doPrivileged(new PrivilegedAction() { @Override public Object run() { PropertyAccess.addTrustedPrefix("newt."); diff --git a/src/newt/classes/jogamp/newt/NEWTJNILibLoader.java b/src/newt/classes/jogamp/newt/NEWTJNILibLoader.java index fde3de222..e2bf86002 100644 --- a/src/newt/classes/jogamp/newt/NEWTJNILibLoader.java +++ b/src/newt/classes/jogamp/newt/NEWTJNILibLoader.java @@ -39,11 +39,11 @@ package jogamp.newt; -import java.security.AccessController; import java.security.PrivilegedAction; import com.jogamp.common.jvm.JNILibLoaderBase; import com.jogamp.common.os.Platform; +import com.jogamp.common.util.SecurityUtil; import com.jogamp.common.util.cache.TempJarCache; public class NEWTJNILibLoader extends JNILibLoaderBase { @@ -52,7 +52,7 @@ public class NEWTJNILibLoader extends JNILibLoaderBase { * i.e. X11 for Unix, GDI for Windows .. and so forth. */ public static boolean loadNEWTHead() { - return AccessController.doPrivileged(new PrivilegedAction() { + return SecurityUtil.doPrivileged(new PrivilegedAction() { @Override public Boolean run() { Platform.initSingleton(); @@ -68,7 +68,7 @@ public class NEWTJNILibLoader extends JNILibLoaderBase { * Loads the NEWT native library for the drm/gbm display. */ public static boolean loadNEWTDrmGbm() { - return AccessController.doPrivileged(new PrivilegedAction() { + return SecurityUtil.doPrivileged(new PrivilegedAction() { @Override public Boolean run() { Platform.initSingleton(); -- cgit v1.2.3