From 262fa8a4b5f0e5859a4f059e0bb16a94e7bbe781 Mon Sep 17 00:00:00 2001 From: Tom Tromey Date: Mon, 22 Jan 2007 23:04:16 +0000 Subject: [PATCH] re PR java/29812 (env->klass value is not updated during the native calls) PR java/29812: * testsuite/libjava.jni/pr29812.java: New file. * testsuite/libjava.jni/pr29812_injar.java: New file. * testsuite/libjava.jni/pr29812_injar.jar: New file. * testsuite/libjava.jni/pr29812.out: New file. * testsuite/libjava.jni/pr29812_injar.c: New file. * testsuite/libjava.jni/pr29812_injar.h: New file. * testsuite/libjava.jni/pr29812.jar: New file. * testsuite/libjava.jni/pr29812.c: New file. * testsuite/libjava.jni/pr29812.h: New file. * testsuite/libjava.jni/jni.exp (gcj_jni_get_cxxflags_invocation): New proc. (gcj_jni_invocation_test_one): Use it. (gcj_jni_pr29812): New proc. (gcj_jni_run): Use it. * java/lang/natRuntime.cc (_load): Push a new system frame before calling JNI_OnLoad. * include/jvm.h (_Jv_JNI_PopSystemFrame): Declare. (_Jv_GetJNIEnvNewFrameWithLoader): Likewise. * jni.cc (struct _Jv_JNI_LocalFrame) : Now unsigned char. : Now bool. : New field. (_Jv_JNI_EnsureLocalCapacity): Updated. (_Jv_JNI_NewLocalRef): Likewise. (_Jv_JNI_NewLocalRef): Likewise. (_Jv_JNI_PopLocalFrame): Likewise. (_Jv_JNI_FindClass): Likewise. (_Jv_GetJNIEnvNewFrame): Likewise. (_Jv_JNI_AttachCurrentThread): Likewise. (_Jv_GetJNIEnvNewFrameWithLoader): New function. (_Jv_GetJNIEnvNewFrame): Use it. * include/jni_md.h (_CLASSPATH_JNIENV_CONTENTS): Removed 'klass'. From-SVN: r121064 --- libjava/ChangeLog | 35 +++++++++ libjava/include/jni_md.h | 5 +- libjava/include/jvm.h | 4 +- libjava/java/lang/natRuntime.cc | 7 ++ libjava/jni.cc | 61 +++++++++------- libjava/testsuite/libjava.jni/jni.exp | 89 +++++++++++++++++------ libjava/testsuite/libjava.jni/pr29812.c | 7 ++ libjava/testsuite/libjava.jni/pr29812.h | 19 +++++ libjava/testsuite/libjava.jni/pr29812.jar | Bin 0 -> 964 bytes libjava/testsuite/libjava.jni/pr29812.java | 25 +++++++ libjava/testsuite/libjava.jni/pr29812.out | 0 libjava/testsuite/libjava.jni/pr29812_injar.c | 26 +++++++ libjava/testsuite/libjava.jni/pr29812_injar.h | 19 +++++ libjava/testsuite/libjava.jni/pr29812_injar.jar | Bin 0 -> 1045 bytes libjava/testsuite/libjava.jni/pr29812_injar.java | 12 +++ 15 files changed, 255 insertions(+), 54 deletions(-) create mode 100644 libjava/testsuite/libjava.jni/pr29812.c create mode 100644 libjava/testsuite/libjava.jni/pr29812.h create mode 100644 libjava/testsuite/libjava.jni/pr29812.jar create mode 100644 libjava/testsuite/libjava.jni/pr29812.java create mode 100644 libjava/testsuite/libjava.jni/pr29812.out create mode 100644 libjava/testsuite/libjava.jni/pr29812_injar.c create mode 100644 libjava/testsuite/libjava.jni/pr29812_injar.h create mode 100644 libjava/testsuite/libjava.jni/pr29812_injar.jar create mode 100644 libjava/testsuite/libjava.jni/pr29812_injar.java diff --git a/libjava/ChangeLog b/libjava/ChangeLog index 8d90a4c332b..e31a214d462 100644 --- a/libjava/ChangeLog +++ b/libjava/ChangeLog @@ -1,5 +1,40 @@ 2007-01-22 Tom Tromey + PR java/29812: + * testsuite/libjava.jni/pr29812.java: New file. + * testsuite/libjava.jni/pr29812_injar.java: New file. + * testsuite/libjava.jni/pr29812_injar.jar: New file. + * testsuite/libjava.jni/pr29812.out: New file. + * testsuite/libjava.jni/pr29812_injar.c: New file. + * testsuite/libjava.jni/pr29812_injar.h: New file. + * testsuite/libjava.jni/pr29812.jar: New file. + * testsuite/libjava.jni/pr29812.c: New file. + * testsuite/libjava.jni/pr29812.h: New file. + * testsuite/libjava.jni/jni.exp (gcj_jni_get_cxxflags_invocation): + New proc. + (gcj_jni_invocation_test_one): Use it. + (gcj_jni_pr29812): New proc. + (gcj_jni_run): Use it. + * java/lang/natRuntime.cc (_load): Push a new system frame before + calling JNI_OnLoad. + * include/jvm.h (_Jv_JNI_PopSystemFrame): Declare. + (_Jv_GetJNIEnvNewFrameWithLoader): Likewise. + * jni.cc (struct _Jv_JNI_LocalFrame) : Now unsigned char. + : Now bool. + : New field. + (_Jv_JNI_EnsureLocalCapacity): Updated. + (_Jv_JNI_NewLocalRef): Likewise. + (_Jv_JNI_NewLocalRef): Likewise. + (_Jv_JNI_PopLocalFrame): Likewise. + (_Jv_JNI_FindClass): Likewise. + (_Jv_GetJNIEnvNewFrame): Likewise. + (_Jv_JNI_AttachCurrentThread): Likewise. + (_Jv_GetJNIEnvNewFrameWithLoader): New function. + (_Jv_GetJNIEnvNewFrame): Use it. + * include/jni_md.h (_CLASSPATH_JNIENV_CONTENTS): Removed 'klass'. + +2007-01-22 Tom Tromey + * libtool-version: Bump current to 9. 2007-01-22 Andrew Haley diff --git a/libjava/include/jni_md.h b/libjava/include/jni_md.h index c550338acd7..6ea90ab4c36 100644 --- a/libjava/include/jni_md.h +++ b/libjava/include/jni_md.h @@ -1,5 +1,5 @@ /* jni_md.h - Copyright (C) 2001, 2005 Free Software Foundation, Inc. + Copyright (C) 2001, 2005, 2007 Free Software Foundation, Inc. This file is part of GNU Classpath. @@ -58,9 +58,6 @@ typedef struct _Jv_JavaVM JavaVM; /* The current exception. */ \ jthrowable ex; \ \ - /* The class of the current native method. */ \ - jclass klass; \ - \ /* The chain of local frames. */ \ struct _Jv_JNI_LocalFrame *locals; \ \ diff --git a/libjava/include/jvm.h b/libjava/include/jvm.h index 2da13bca4dc..9a99a954b28 100644 --- a/libjava/include/jvm.h +++ b/libjava/include/jvm.h @@ -592,8 +592,8 @@ void _Jv_SetCurrentJNIEnv (_Jv_JNIEnv *); /* Free a JNIEnv. */ void _Jv_FreeJNIEnv (_Jv_JNIEnv *); -/* Free a JNIEnv. */ -void _Jv_FreeJNIEnv (_Jv_JNIEnv *); +extern "C" void _Jv_JNI_PopSystemFrame (_Jv_JNIEnv *); +_Jv_JNIEnv *_Jv_GetJNIEnvNewFrameWithLoader (::java::lang::ClassLoader *); struct _Jv_JavaVM; _Jv_JavaVM *_Jv_GetJavaVM (); diff --git a/libjava/java/lang/natRuntime.cc b/libjava/java/lang/natRuntime.cc index ecaf7d314a2..64c8fbb3f90 100644 --- a/libjava/java/lang/natRuntime.cc +++ b/libjava/java/lang/natRuntime.cc @@ -207,7 +207,14 @@ java::lang::Runtime::_load (jstring path, jboolean do_search) // FIXME: what? return; } + + // Push a new frame so that JNI_OnLoad will get the right class + // loader if it calls FindClass. + ::java::lang::ClassLoader *loader + = _Jv_StackTrace::GetFirstNonSystemClassLoader(); + JNIEnv *env = _Jv_GetJNIEnvNewFrameWithLoader (loader); jint vers = ((jint (JNICALL *) (JavaVM *, void *)) onload) (vm, NULL); + _Jv_JNI_PopSystemFrame (env); if (vers != JNI_VERSION_1_1 && vers != JNI_VERSION_1_2 && vers != JNI_VERSION_1_4) { diff --git a/libjava/jni.cc b/libjava/jni.cc index 9dc9780f9a0..59c1e5fd03e 100644 --- a/libjava/jni.cc +++ b/libjava/jni.cc @@ -85,16 +85,18 @@ extern struct JNIInvokeInterface _Jv_JNI_InvokeFunctions; // This structure is used to keep track of local references. struct _Jv_JNI_LocalFrame { - // This is true if this frame object represents a pushed frame (eg - // from PushLocalFrame). - int marker; + // This is one of the MARK_ constants. + unsigned char marker; // Flag to indicate some locals were allocated. - int allocated_p; + bool allocated_p; // Number of elements in frame. int size; + // The class loader of the JNI method that allocated this frame. + ::java::lang::ClassLoader *loader; + // Next frame in chain. _Jv_JNI_LocalFrame *next; @@ -311,8 +313,9 @@ _Jv_JNI_EnsureLocalCapacity (JNIEnv *env, jint size) frame->marker = MARK_NONE; frame->size = size; - frame->allocated_p = 0; + frame->allocated_p = false; memset (&frame->vec[0], 0, size * sizeof (jobject)); + frame->loader = env->locals->loader; frame->next = env->locals; env->locals = frame; @@ -350,7 +353,7 @@ _Jv_JNI_NewLocalRef (JNIEnv *env, jobject obj) set = true; done = true; frame->vec[i] = obj; - frame->allocated_p = 1; + frame->allocated_p = true; break; } } @@ -368,7 +371,7 @@ _Jv_JNI_NewLocalRef (JNIEnv *env, jobject obj) _Jv_JNI_EnsureLocalCapacity (env, 16); // We know the first element of the new frame will be ok. env->locals->vec[0] = obj; - env->locals->allocated_p = 1; + env->locals->allocated_p = true; } mark_for_gc (obj, local_ref_table); @@ -397,7 +400,7 @@ _Jv_JNI_PopLocalFrame (JNIEnv *env, jobject result, int stop) { if (rf->allocated_p) memset (&rf->vec[0], 0, rf->size * sizeof (jobject)); - rf->allocated_p = 0; + rf->allocated_p = false; rf = NULL; break; } @@ -541,8 +544,8 @@ _Jv_JNI_FindClass (JNIEnv *env, const char *name) jstring n = JvNewStringUTF (s); java::lang::ClassLoader *loader = NULL; - if (env->klass != NULL) - loader = env->klass->getClassLoaderInternal (); + if (env->locals->loader != NULL) + loader = env->locals->loader; if (loader == NULL) { @@ -2087,18 +2090,14 @@ mangled_name (jclass klass, _Jv_Utf8Const *func_name, buf[here] = '\0'; } -// Return the current thread's JNIEnv; if one does not exist, create -// it. Also create a new system frame for use. This is `extern "C"' -// because the compiler calls it. -extern "C" JNIEnv * -_Jv_GetJNIEnvNewFrame (jclass klass) +JNIEnv * +_Jv_GetJNIEnvNewFrameWithLoader (::java::lang::ClassLoader *loader) { JNIEnv *env = _Jv_GetCurrentJNIEnv (); if (__builtin_expect (env == NULL, false)) { env = (JNIEnv *) _Jv_MallocUnchecked (sizeof (JNIEnv)); env->p = &_Jv_JNIFunctions; - env->klass = klass; env->locals = NULL; // We set env->ex below. @@ -2107,11 +2106,12 @@ _Jv_GetJNIEnvNewFrame (jclass klass) _Jv_MallocUnchecked (sizeof (_Jv_JNI_LocalFrame) + (FRAME_SIZE * sizeof (jobject))); - + env->bottom_locals->marker = MARK_SYSTEM; env->bottom_locals->size = FRAME_SIZE; env->bottom_locals->next = NULL; - env->bottom_locals->allocated_p = 0; + env->bottom_locals->allocated_p = false; + // We set the klass field below. memset (&env->bottom_locals->vec[0], 0, env->bottom_locals->size * sizeof (jobject)); @@ -2123,23 +2123,25 @@ _Jv_GetJNIEnvNewFrame (jclass klass) // built, above. if (__builtin_expect (env->locals == NULL, true)) - env->locals = env->bottom_locals; - + { + env->locals = env->bottom_locals; + env->locals->loader = loader; + } else { // Alternatively, we might be re-entering JNI, in which case we can't // reuse the bottom_locals frame, because it is already underneath // us. So we need to make a new one. - _Jv_JNI_LocalFrame *frame = (_Jv_JNI_LocalFrame *) _Jv_MallocUnchecked (sizeof (_Jv_JNI_LocalFrame) + (FRAME_SIZE * sizeof (jobject))); - + frame->marker = MARK_SYSTEM; frame->size = FRAME_SIZE; - frame->allocated_p = 0; + frame->allocated_p = false; frame->next = env->locals; + frame->loader = loader; memset (&frame->vec[0], 0, frame->size * sizeof (jobject)); @@ -2152,6 +2154,15 @@ _Jv_GetJNIEnvNewFrame (jclass klass) return env; } +// Return the current thread's JNIEnv; if one does not exist, create +// it. Also create a new system frame for use. This is `extern "C"' +// because the compiler calls it. +extern "C" JNIEnv * +_Jv_GetJNIEnvNewFrame (jclass klass) +{ + return _Jv_GetJNIEnvNewFrameWithLoader (klass->getClassLoaderInternal()); +} + // Destroy the env's reusable resources. This is called from the thread // destructor "finalize_native" in natThread.cc void @@ -2392,7 +2403,6 @@ _Jv_JNI_AttachCurrentThread (JavaVM *, jstring name, void **penv, return JNI_ERR; env->p = &_Jv_JNIFunctions; env->ex = NULL; - env->klass = NULL; env->bottom_locals = (_Jv_JNI_LocalFrame *) _Jv_MallocUnchecked (sizeof (_Jv_JNI_LocalFrame) + (FRAME_SIZE @@ -2404,9 +2414,10 @@ _Jv_JNI_AttachCurrentThread (JavaVM *, jstring name, void **penv, return JNI_ERR; } - env->locals->allocated_p = 0; + env->locals->allocated_p = false; env->locals->marker = MARK_SYSTEM; env->locals->size = FRAME_SIZE; + env->locals->loader = NULL; env->locals->next = NULL; for (int i = 0; i < env->locals->size; ++i) diff --git a/libjava/testsuite/libjava.jni/jni.exp b/libjava/testsuite/libjava.jni/jni.exp index 5fa6edefb71..1fff2b2f019 100644 --- a/libjava/testsuite/libjava.jni/jni.exp +++ b/libjava/testsuite/libjava.jni/jni.exp @@ -101,7 +101,8 @@ proc gcj_jni_test_one {file} { # The base name. We use it for several purposes. set main [file rootname [file tail $file]] - if {! [runtest_file_p $runtests $main]} { + if {! [runtest_file_p $runtests $main] + || $main == "pr29812" || $main == "pr29812_injar"} { # Simply skip it. return 1 } @@ -235,6 +236,33 @@ proc gcj_jni_invocation_compile_c_to_binary {file {options {}}} { return 1 } +proc gcj_jni_get_cxxflags_invocation {} { + # Darwin needs -liconv linked, otherwise we get some unresolved. + # If you're building the compiler with --prefix set to a place + # where it's not yet installed, then the linker won't be able to + # find the libgcc used by libffi.dylib. We could pass the + # -dylib_file option, but that's complicated, and it's much easier + # to just make the linker find libgcc using -L options. + # Similar logic applies to libgcj. + if { [istarget "*-*-darwin*"] } { + set cxxflags "-L../.libs -shared-libgcc -ljvm -lgcj -liconv" + } else { + global LIBJAVA + if [info exists LIBJAVA] { + set libjava $LIBJAVA; + } else { + set libjava [libjava_find_lib libjava gcj] + } + set cxxflags "$libjava -ljvm" + } + + if { [istarget "*-*-solaris*"] } { + lappend cxxflags "-lsocket" + } + + return $cxxflags +} + # Do all the work for a single invocation API test. Return 0 on # failure. proc gcj_jni_invocation_test_one {file} { @@ -259,29 +287,8 @@ proc gcj_jni_invocation_test_one {file} { # pass "bytecompile $file" set cfile [file rootname $file].c - # Darwin needs -liconv linked, otherwise we get some unresolved. - # If you're building the compiler with --prefix set to a place - # where it's not yet installed, then the linker won't be able to - # find the libgcc used by libffi.dylib. We could pass the - # -dylib_file option, but that's complicated, and it's much easier - # to just make the linker find libgcc using -L options. - # Similar logic applies to libgcj. - if { [istarget "*-*-darwin*"] } { - set cxxflags "-L../.libs -shared-libgcc -ljvm -lgcj -liconv" - } else { - global LIBJAVA - if [info exists LIBJAVA] { - set libjava $LIBJAVA; - } else { - set libjava [libjava_find_lib libjava gcj] - } - set cxxflags "$libjava -ljvm" - } - - if { [istarget "*-*-solaris*"] } { - lappend cxxflags "-lsocket" - } + set cxxflags [gcj_jni_get_cxxflags_invocation] if {! [gcj_jni_invocation_compile_c_to_binary $cfile $cxxflags]} { # FIXME return 0 @@ -309,6 +316,40 @@ proc gcj_jni_invocation_test_one {file} { return 1 } +proc gcj_jni_pr29812 {} { + global srcdir subdir + global INTERPRETER runtests + + # Set up a global we need. + libjava_arguments + + set b ${srcdir}/${subdir} + + if {! [runtest_file_p $runtests pr29812]} { + # Simply skip it. + return 1 + } + + if {! [gcj_jni_compile_c_to_so $b/pr29812.c ""]} { + return 0 + } + if {! [gcj_jni_compile_c_to_so $b/pr29812_injar.c ""]} { + return 0 + } + + set gij [libjava_find_gij] + if {$INTERPRETER == "yes" && $gij != ""} { + if {! [libjava_invoke pr29812 "gij test" opts $gij \ + "" $b/pr29812.out "" \ + -classpath $b/pr29812.jar pr29812 $b/pr29812_injar.jar]} { + return 0 + } + } + + # When we succeed we remove all our clutter. + eval gcj_cleanup [glob -nocomplain -- *pr29812*] +} + # Run the JNI tests. proc gcj_jni_run {} { global srcdir subdir @@ -328,6 +369,8 @@ proc gcj_jni_run {} { foreach x $srcfiles { gcj_jni_invocation_test_one $x } + + gcj_jni_pr29812 } else { verbose "JNI tests not run in cross-compilation environment" } diff --git a/libjava/testsuite/libjava.jni/pr29812.c b/libjava/testsuite/libjava.jni/pr29812.c new file mode 100644 index 00000000000..809d5ed2e80 --- /dev/null +++ b/libjava/testsuite/libjava.jni/pr29812.c @@ -0,0 +1,7 @@ +#include + +void +Java_pr29812_baseN (JNIEnv *env, jclass barf) +{ + /* nothing */ +} diff --git a/libjava/testsuite/libjava.jni/pr29812.h b/libjava/testsuite/libjava.jni/pr29812.h new file mode 100644 index 00000000000..70d19993831 --- /dev/null +++ b/libjava/testsuite/libjava.jni/pr29812.h @@ -0,0 +1,19 @@ +/* DO NOT EDIT THIS FILE - it is machine generated */ + +#include + +#ifndef __pr29812__ +#define __pr29812__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +JNIEXPORT void JNICALL Java_pr29812_baseN (JNIEnv *env, jclass); + +#ifdef __cplusplus +} +#endif + +#endif /* __pr29812__ */ diff --git a/libjava/testsuite/libjava.jni/pr29812.jar b/libjava/testsuite/libjava.jni/pr29812.jar new file mode 100644 index 0000000000000000000000000000000000000000..c3cf6aba0b52d97a54d8e86d5487c08a1620f57a GIT binary patch literal 964 zcwP(eW@h1H00FZsGcyJxzzM{@t|5-Po_=on0Vv9L=;kKs0NEfcf~?Hf(a+P(H8@1i z*UdLEFEcH*xI{NBwWv5VKhH|RP|twNxhOTUBsE3XsnSZpK+n=hH$6F-iwkBt2ZI>U z^ute7zj`q-FuZ4GVBiIc78Ds-S{NGXCFdj-7ncU#E)sGSusxhR{VbcH4@>f%hCn^f zunQSGSc0csQf~?sN)D{tASQ8A>CLifz9#dZaxd|D$^Ij7nr%#r#GLk<^WI&4ex~I6 zzh8g4-HNnbvtgryZp!lKNWsS zo9eL1rwcR#7I;PMm=tRJ-g3|CBtgcu*1o0Yr`_&edt2PL)TNT``Hi-lS{(bNQx89x zdO2_IZT70Yhb3!{E?mH5?xfZ9!LZ_WRe!k0p4HN7hl?I%*v}yKDG3mpcQ-AqAj&ko&`6O2UZD(~v+&}hDbe*~|wz0dc z@yjIjAL9GH;wL`zJ0VwesxmZhL!r-tq@um53E6vHWE# zpzzdSgp_MCw*0egB! ZfK~>y)F0r@$_A2P2Er{s`WF+32LQ?DUL literal 0 HcwPel00001 diff --git a/libjava/testsuite/libjava.jni/pr29812.java b/libjava/testsuite/libjava.jni/pr29812.java new file mode 100644 index 00000000000..4dde744bee3 --- /dev/null +++ b/libjava/testsuite/libjava.jni/pr29812.java @@ -0,0 +1,25 @@ +import java.io.File; +import java.net.*; +import java.lang.reflect.Method; + +public class pr29812 +{ + static { + System.loadLibrary("pr29812"); + } + + public static native void baseN(); + + public static void main(String[] args) throws Throwable + { + // Make sure JNI environment is initialized. + baseN(); + + File jar = new File(args[0]); + URL u = jar.toURL(); + URLClassLoader uc = new URLClassLoader(new URL[] { u }); + Class k = uc.loadClass("pr29812_injar"); + Method m = k.getMethod("doit", (Class[]) null); + m.invoke(null, (Object[]) null); + } +} diff --git a/libjava/testsuite/libjava.jni/pr29812.out b/libjava/testsuite/libjava.jni/pr29812.out new file mode 100644 index 00000000000..e69de29bb2d diff --git a/libjava/testsuite/libjava.jni/pr29812_injar.c b/libjava/testsuite/libjava.jni/pr29812_injar.c new file mode 100644 index 00000000000..5b045ce72a8 --- /dev/null +++ b/libjava/testsuite/libjava.jni/pr29812_injar.c @@ -0,0 +1,26 @@ + +#include +#include +#include + +JNIEXPORT jint JNICALL +JNI_OnLoad (JavaVM *vm, void *nothing) +{ + JNIEnv *env; + jint r; + jclass k; + + r = (*vm)->GetEnv (vm, (void **) &env, JNI_VERSION_1_2); + assert (r == JNI_OK); + k = (*env)->FindClass (env, "pr29812_injar$inner"); + assert (k != NULL); + + return JNI_VERSION_1_2; +} + +void +Java_pr29812_1injar_doit (JNIEnv *env, jclass b) +{ + jclass k = (*env)->FindClass(env, "pr29812_injar$inner"); + assert (k != NULL); +} diff --git a/libjava/testsuite/libjava.jni/pr29812_injar.h b/libjava/testsuite/libjava.jni/pr29812_injar.h new file mode 100644 index 00000000000..40f74ff393f --- /dev/null +++ b/libjava/testsuite/libjava.jni/pr29812_injar.h @@ -0,0 +1,19 @@ +/* DO NOT EDIT THIS FILE - it is machine generated */ + +#include + +#ifndef __pr29812_1injar__ +#define __pr29812_1injar__ + +#ifdef __cplusplus +extern "C" +{ +#endif + +JNIEXPORT void JNICALL Java_pr29812_1injar_doit (JNIEnv *env, jclass); + +#ifdef __cplusplus +} +#endif + +#endif /* __pr29812_1injar__ */ diff --git a/libjava/testsuite/libjava.jni/pr29812_injar.jar b/libjava/testsuite/libjava.jni/pr29812_injar.jar new file mode 100644 index 0000000000000000000000000000000000000000..438dc0063b594f56d95bb44bd6b3b3edbe37e0d0 GIT binary patch literal 1045 zcwP(eW@h1H00EmUGcyJxzzM{@t|5-Po_=on0Vv9L=;kKs0NEfcf~?Hf(a+P(H8@1i z*UdLEFEcH*xI{NBwWv5VKhH|RP|twNxhOTUBsE3XsnSZpK+n=hH$6F-iwkBt2ZJck z^u^BUw(^V&46}h)7${m$WMpY!XcV8Bmz7wgmzwm~WpqBYdbI_KiA5$wX zR5fm`%1f(usD$PmgPMbO!eH?R(*JQAoY!*)w7JVxj)~p*k5$4dlP>^V*bn{>c5`KPm?G(cW=X2 z_wv(9fwH;h4xYWe^nJo|5#=|Z?y~=7Kn+ix`f0O10eSww@RURkPnFEPyi{nY#`^nu z9|nf%CDf3bV><5QAJ-8Hr8+t&96hAnXQDB3ycu+yyT4{N8bu5{&C zWgh$OJm<$X7fl~tnrgOdm)er%`mK-Eow9dT1j-6*Q{E!j^5J5y!UpFL?B@i|ZwV|v z{oUuL`%KX;0Xv;(W$W^`2xlfgnYp`1;O?&I<*hp2pMoey0+tQYirjrx}j{I`Gs#mL0PfII!8 z0;Jr4str9qAb>gp_S}Im0ehN9fK~>qIRM=N^hid4tBiP}Jiwck4Wx(#2pNG2|1p7h E0N$o$IRF3v literal 0 HcwPel00001 diff --git a/libjava/testsuite/libjava.jni/pr29812_injar.java b/libjava/testsuite/libjava.jni/pr29812_injar.java new file mode 100644 index 00000000000..9dc32a3cdcd --- /dev/null +++ b/libjava/testsuite/libjava.jni/pr29812_injar.java @@ -0,0 +1,12 @@ +public class pr29812_injar +{ + public class inner + { + } + + static { + System.loadLibrary("pr29812_injar"); + } + + public static native void doit(); +} -- 2.11.4.GIT