This is the mail archive of the java-prs@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug java/16923] New: Options passed to JNI_CreateJavaVM are ignored


Options that are passed in the JavaVMInitArgs structure passed to the
JNI_CreateJavaVM function seems to be completely ignored. The following code
should result in a setting of the system property "some.property" but it doesn't.

	JNIEnv* env;
	JavaVMInitArgs vm_args;
	JavaVMOption options[1];

	options[0].optionString = "-Dsome.property=propval";
	options[0].extraInfo = 0;

	vm_args.nOptions = 1;
	vm_args.options  = &options;
	vm_args.version  = JNI_VERSION_1_4;
	vm_args.ignoreUnrecognized = JNI_TRUE;

	if(JNI_CreateJavaVM(&s_javaVM, (void **)&env, &vm_args) != JNI_OK) {
		fputs("Unable to create Java VM\n", stderr);
		return 1;
	}

-- 
           Summary: Options passed to JNI_CreateJavaVM are ignored
           Product: gcc
           Version: 3.4.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: java
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: thhal at mailblocks dot com
                CC: gcc-bugs at gcc dot gnu dot org,java-prs at gcc dot gnu
                    dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16923


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]