src/macosx/classes/com/apple/eawt/Application.java

Print this page

        

@@ -26,11 +26,10 @@
 package com.apple.eawt;
 
 import java.awt.*;
 import java.awt.peer.*;
 import java.beans.Beans;
-import java.security.PrivilegedAction;
 
 import javax.swing.JMenuBar;
 
 import sun.lwawt.*;
 import sun.lwawt.macosx.*;

@@ -57,11 +56,17 @@
     private static native void nativeInitializeApplicationDelegate();
 
     static Application sApplication = null;
 
     static {
-        java.security.AccessController.doPrivileged((PrivilegedAction<?>)new sun.security.action.LoadLibraryAction("awt"));
+        java.security.AccessController.doPrivileged(
+            new java.security.PrivilegedAction<Void>() {
+                public Void run() {
+                    System.loadLibrary("awt");
+                    return null;
+                }
+            });
 
         checkSecurity();
         if (!Beans.isDesignTime()) {
             nativeInitializeApplicationDelegate();
         }