diff options
author | Thomas Fitzsimmons <fitzsim@redhat.com> | 2005-02-23 17:36:26 +0000 |
---|---|---|
committer | Thomas Fitzsimmons <fitzsim@gcc.gnu.org> | 2005-02-23 17:36:26 +0000 |
commit | bc71e4a22b8d2b894a283f34974aeba11a28bb96 (patch) | |
tree | 9b2cca6c033589c537e103cd0b5bbf64f75f3359 /libjava/java | |
parent | c150a271b1fa7ad02b245dea1579b3f2e981e85a (diff) | |
download | gcc-bc71e4a22b8d2b894a283f34974aeba11a28bb96.zip gcc-bc71e4a22b8d2b894a283f34974aeba11a28bb96.tar.gz gcc-bc71e4a22b8d2b894a283f34974aeba11a28bb96.tar.bz2 |
re PR libgcj/16923 (-D* Options passed to JNI_CreateJavaVM are ignored)
2005-02-23 Thomas Fitzsimmons <fitzsim@redhat.com>
PR libgcj/16923
* gcj.texi (Invocation): Add descriptions of JvVMInitArgs and
JvVMOption.
2005-02-23 Thomas Fitzsimmons <fitzsim@redhat.com>
PR libgcj/16923
* jni.cc (JNI_CreateJavaVM): Check JNI version. Cast args to
JvVMInitArgs. Pass args to _Jv_CreateJavaVM and check return
value. Move argument parsing code to prims.cc.
* prims.cc (no_properties): Remove.
(_Jv_Compiler_Properties): Initialize to NULL.
(_Jv_Properties_Count): Initialize to 0.
(parse_verbose_args): New function.
(parse_init_args): New function.
(_Jv_CreateJavaVM): Call parse_init_args.
(_Jv_RunMain): Check return value of _Jv_CreateJavaVM.
* gcj/cni.h (JvVMOption): New struct.
(JvVMInitArgs): Likewise.
(JvCreateJavaVM): Declare vm_args as JvVMInitArgs* rather than
void*.
* libjava/gcj/javaprims.h (_Jv_VMOption): New struct.
(_Jv_VMInitArgs): Likewise.
* include/java-props.h (_Jv_Properties_Count): Declare.
* java/lang/natRuntime.cc (insertSystemProperties): Use
_Jv_Properties_Count in for loop exit condition.
* testsuite/libjava.jni/jni.exp
(gcj_invocation_compile_c_to_binary): New procedure.
(gcj_invocation_test_one): Likewise.
(gcj_jni_run): Run JNI invocation API tests.
* testsuite/libjava.jni/invocation/PR16923.c,
testsuite/libjava.jni/invocation/PR16923.java,
testsuite/libjava.jni/invocation/PR16923.out: New test.
From-SVN: r95459
Diffstat (limited to 'libjava/java')
-rw-r--r-- | libjava/java/lang/natRuntime.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libjava/java/lang/natRuntime.cc b/libjava/java/lang/natRuntime.cc index 37d7b4b..31f9b90 100644 --- a/libjava/java/lang/natRuntime.cc +++ b/libjava/java/lang/natRuntime.cc @@ -557,7 +557,7 @@ java::lang::Runtime::insertSystemProperties (java::util::Properties *newprops) // `-D'. Important: after this point, the only properties that // should be set are those which either the user cannot meaningfully // override, or which augment whatever value the user has provided. - for (int i = 0; _Jv_Compiler_Properties[i]; ++i) + for (int i = 0; i < _Jv_Properties_Count; ++i) { const char *s, *p; // Find the `='. |