src/java.base/solaris/classes/sun/nio/fs/SolarisNativeDispatcher.java
changeset 55693 9a97b1393e72
parent 47216 71c04702a3d5
equal deleted inserted replaced
55692:64330bbb9be5 55693:9a97b1393e72
     1 /*
     1 /*
     2  * Copyright (c) 2008, 2012, Oracle and/or its affiliates. All rights reserved.
     2  * Copyright (c) 2008, 2019, Oracle and/or its affiliates. All rights reserved.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     4  *
     4  *
     5  * This code is free software; you can redistribute it and/or modify it
     5  * This code is free software; you can redistribute it and/or modify it
     6  * under the terms of the GNU General Public License version 2 only, as
     6  * under the terms of the GNU General Public License version 2 only, as
     7  * published by the Free Software Foundation.  Oracle designates this
     7  * published by the Free Software Foundation.  Oracle designates this
    23  * questions.
    23  * questions.
    24  */
    24  */
    25 
    25 
    26 package sun.nio.fs;
    26 package sun.nio.fs;
    27 
    27 
    28 import java.security.AccessController;
       
    29 import java.security.PrivilegedAction;
       
    30 
       
    31 /**
    28 /**
    32  * Solaris specific system calls.
    29  * Solaris specific system calls.
    33  */
    30  */
    34 
    31 
    35 class SolarisNativeDispatcher extends UnixNativeDispatcher {
    32 class SolarisNativeDispatcher extends UnixNativeDispatcher {
    50 
    47 
    51     // initialize
    48     // initialize
    52     private static native void init();
    49     private static native void init();
    53 
    50 
    54     static {
    51     static {
    55         AccessController.doPrivileged(new PrivilegedAction<Void>() {
    52         jdk.internal.loader.BootLoader.loadLibrary("nio");
    56             public Void run() {
       
    57                 System.loadLibrary("nio");
       
    58                 return null;
       
    59         }});
       
    60         init();
    53         init();
    61     }
    54     }
    62 }
    55 }