ignore jnigraphics load errors

Nexus 4 w/ Android 5.0 Lollipop produces the following error message:

java.lang.UnsatisfiedLinkError: Shared library "/system/lib/libjnigraphics.so" already opened by ClassLoader 0x0
This commit is contained in:
jmakovicka 2014-11-25 13:28:27 +01:00
parent 2e1a1954d7
commit eb4967e6f0

View file

@ -52,10 +52,8 @@ public class NativeOsmandLibrary extends NativeLibrary {
try {
System.loadLibrary("jnigraphics");
} catch( UnsatisfiedLinkError e ) {
// tolerate missing jnigraphics on Lollipop
// handle "Shared library already opened" error
log.debug("Failed to load jnigraphics: " + e); //$NON-NLS-1$
if (android.os.Build.VERSION.SDK_INT <= 20)
throw e;
}
}
final String libCpuSuffix = cpuHasNeonSupport() ? "_neon" : "";