diff options
author | Sven Gothel <[email protected]> | 2011-02-26 20:14:40 +0100 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2011-02-26 20:14:40 +0100 |
commit | 7b9c3dd1d42b8e8bd1caea8e2caf8f3e15e3ff8f (patch) | |
tree | aab62e917f535713846bcba3b86a7ad6a8f9f6eb /src/java/com/jogamp/common/os | |
parent | 47e9c21909034ef2d68937ec970a1c8c3b380ada (diff) |
RecursiveLock: static field -> final; NativeLibrary: cleanup
Diffstat (limited to 'src/java/com/jogamp/common/os')
-rwxr-xr-x | src/java/com/jogamp/common/os/NativeLibrary.java | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/src/java/com/jogamp/common/os/NativeLibrary.java b/src/java/com/jogamp/common/os/NativeLibrary.java index 2c7e596..b597635 100755 --- a/src/java/com/jogamp/common/os/NativeLibrary.java +++ b/src/java/com/jogamp/common/os/NativeLibrary.java @@ -252,14 +252,15 @@ public class NativeLibrary implements DynamicLookupHelper { ClassLoader loader) { List paths = new ArrayList(); String libName = selectName(windowsLibName, unixLibName, macOSXLibName); - if (libName == null) + if (libName == null) { return paths; + } // Allow user's full path specification to override our building of paths File file = new File(libName); if (file.isAbsolute()) { - paths.add(libName); - return paths; + paths.add(libName); + return paths; } String[] baseNames = buildNames(libName); @@ -314,9 +315,7 @@ public class NativeLibrary implements DynamicLookupHelper { if (!searchSystemPathFirst) { // Add just the library names to use the OS's search algorithm - for (int i = 0; i < baseNames.length; i++) { - paths.add(baseNames[i]); - } + paths.addAll(Arrays.asList(baseNames)); } return paths; |