When I initialize JDK1_1InitArgswith JDK1_1InitArgs vm_args, the compiler gives me errors. I need this variable initialized to use the function JNI_CreateJavaVM.
JavaVM *jvm;
JNIEnv *env;
jmethodID mid;
JDK1_1InitArgs vm_args; // Line 47
vm_args.version = 0x00010001; // Line 48
JNI_GetDefaultJavaVMInitArgs(&vm_args);
vm_args.classpath = "C:/Program Files/Java/jdk1.7.0/lib;.;";
JNI_CreateJavaVM(&jvm, &env, &vm_args);
env = (*jvm)->AttachCurrentThread(jvm,&env,NULL);
jclass cls = (*env)->GetObjectClass(env,Obj);
mid = (*env)->GetMethodID(env,cls,"callBack","(Ljava/lang/String;)V");
(*env)->CallVoidMethodA(env,Obj,mid,(*env)->NewStringUTF(env,"1B"));
Link
Errors:

Why am I getting these errors? How can I get rid of them?
source
share