summaryrefslogtreecommitdiffstats
path: root/src/java/com/jogamp/common/jvm
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2011-11-29 04:59:42 +0100
committerSven Gothel <[email protected]>2011-11-29 04:59:42 +0100
commit04391a3f417e10e1b6dafbd8becc63659af633c3 (patch)
tree2b9a5f8dc81b7631d34d306894387d3bac4b9bec /src/java/com/jogamp/common/jvm
parent60ea6727f1a089f6afd17fcea3bd7d29353af9b4 (diff)
JarUtil: Improve Robustness (Bug 522) and API doc, prepare for Jar-In-Jar. Add unit test.
Misc.: - IOUtil: Add toURL* methods - TempJarCache: Add 'URL getResource(String)'
Diffstat (limited to 'src/java/com/jogamp/common/jvm')
-rw-r--r--src/java/com/jogamp/common/jvm/JNILibLoaderBase.java6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/java/com/jogamp/common/jvm/JNILibLoaderBase.java b/src/java/com/jogamp/common/jvm/JNILibLoaderBase.java
index 3164b82..31e777a 100644
--- a/src/java/com/jogamp/common/jvm/JNILibLoaderBase.java
+++ b/src/java/com/jogamp/common/jvm/JNILibLoaderBase.java
@@ -151,11 +151,11 @@ public class JNILibLoaderBase {
final String nativeJarName = nativeJarBaseName+"-natives-"+Platform.getOSAndArch()+".jar";
final ClassLoader cl = classFromJavaJar.getClassLoader();
try {
- URL jarUrlRoot = JarUtil.getJarURLDirname( JarUtil.getJarURL( classFromJavaJar.getName(), cl ) );
+ URL jarUrlRoot = JarUtil.getURLDirname( JarUtil.getJarSubURL( classFromJavaJar.getName(), cl ) );
if(DEBUG) {
System.err.println("JNILibLoaderBase: addNativeJarLibs: "+nativeJarBaseName+": url-root "+jarUrlRoot);
}
- URL nativeJarURL = JarUtil.getJarURL(jarUrlRoot, nativeJarName);
+ URL nativeJarURL = JarUtil.getJarFileURL(jarUrlRoot, nativeJarName);
if(DEBUG) {
System.err.println("JNILibLoaderBase: addNativeJarLibs: "+nativeJarBaseName+": nativeJarURL "+nativeJarURL);
}
@@ -181,7 +181,7 @@ public class JNILibLoaderBase {
if(TempJarCache.isInitialized()) {
final ClassLoader cl = classFromJavaJar.getClassLoader();
try {
- final String jarName = JarUtil.getJarName(classFromJavaJar.getName(), cl);
+ final String jarName = JarUtil.getJarBasename(classFromJavaJar.getName(), cl);
if(jarName!=null) {
if( null != allJavaJarPrefix && jarName.startsWith(allJavaJarPrefix) ) {
// all-in-one variant