diff options
author | 2015-12-01 01:20:00 +0000 | |
---|---|---|
committer | 2015-12-01 01:20:00 +0000 | |
commit | 1ed1a1320c89a143a8139d331a05d47ed3db64f7 (patch) | |
tree | d0e99aafbf6f4b50d0255ad52278b50d825cebc7 /test/068-classloader/src/Main.java | |
parent | 2d902b99bba7ae1ad77ebeb038a4ef63c3ed6399 (diff) |
Revert "Change LoadNativeLibrary to use GetOrCreateAllocator"
This reverts commit 2d902b99bba7ae1ad77ebeb038a4ef63c3ed6399.
Change-Id: I4a674844f2f6d76d1c33741b46f12417ec7eab35
Diffstat (limited to 'test/068-classloader/src/Main.java')
-rw-r--r-- | test/068-classloader/src/Main.java | 24 |
1 files changed, 0 insertions, 24 deletions
diff --git a/test/068-classloader/src/Main.java b/test/068-classloader/src/Main.java index e3bf82c8c3..361e2938e3 100644 --- a/test/068-classloader/src/Main.java +++ b/test/068-classloader/src/Main.java @@ -14,8 +14,6 @@ * limitations under the License. */ -import java.lang.reflect.Constructor; -import java.lang.reflect.Method; /** * Class loader test. */ @@ -64,28 +62,6 @@ public class Main { testSeparation(); testClassForName(); - - // Attempt to load without a class table, regression test for b/25866849. - testLoadNativeLibrary(args[0]); - } - - static void testLoadNativeLibrary(String libName) throws Exception { - Class pathClassLoader = Class.forName("dalvik.system.PathClassLoader"); - if (pathClassLoader == null) { - throw new AssertionError("Couldn't find path class loader class"); - } - Constructor constructor = - pathClassLoader.getDeclaredConstructor(String.class, ClassLoader.class); - ClassLoader loader = (ClassLoader) constructor.newInstance( - FancyLoader.DEX_FILE, ClassLoader.getSystemClassLoader()); - Runtime runtime = Runtime.getRuntime(); - Method method = runtime.getClass().getDeclaredMethod("loadLibrary", String.class, - ClassLoader.class); - if (method == null) { - throw new RuntimeException("loadLibrary not found"); - } - method.setAccessible(true); - method.invoke(runtime, libName, loader); } static void testSeparation() { |