Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b37cc330 authored by Dianne Hackborn's avatar Dianne Hackborn Committed by Android Git Automerger
Browse files

am b5018723: am 74b1ed32: Fix issue #3113219: NativeActivity using wrong lib path with Java code

Merge commit 'b5018723'

* commit 'b5018723':
  Fix issue #3113219: NativeActivity using wrong lib path with Java code
parents 164cd438 b5018723
Loading
Loading
Loading
Loading
+4 −9
Original line number Diff line number Diff line
@@ -162,16 +162,11 @@ public class NativeActivity extends Activity implements SurfaceHolder.Callback2,
        
        String path = null;
        
        if ((ai.applicationInfo.flags&ApplicationInfo.FLAG_HAS_CODE) == 0) {
            // If the application does not have (Java) code, then no ClassLoader
            // has been set up for it.  We will need to do our own search for
            // the native code.
        File libraryFile = new File(ai.applicationInfo.nativeLibraryDir,
                System.mapLibraryName(libname));
        if (libraryFile.exists()) {
            path = libraryFile.getPath();
        }
        }
        
        if (path == null) {
            throw new IllegalArgumentException("Unable to find native library: " + libname);