use
res = JNI_CreateJavaVM(&jvm, (void **) &env,&vm_args);
but, looking in the previous lines, changes:
vm_args.version = 0x00010001;
to
vm_args.version = JNI_VERSION_1_2;
To me, JNI_CreateJavaVM returned -3 (JNI_EVERSION). Changes the line, the VM is initialized correctly.