System.exit(0) - basic JNI problem

Hi there,

I open C++ GUI application from Java (using JNI native call). When user clicks "x" and closes GUI application, I'd like to shutdown JVM also. In my code, when user clicks "x", C++ side calls Java method (that contains System.exit(0) call) and this results in the java.exe - Application Error: "The instruction at 0x0 referenced at 0x0. The memory couldn't be read".

I use Jace to handle JNI calls but this sounds like a pure JNI problem.

Many thanks in advance.

Kalle.
kalle73Asked:
Who is Participating?

Improve company productivity with a Business Account.Sign Up

x
 
sciuriwareConnect With a Mentor Commented:
No it's alltogether only one program.
;JOOP!
0
 
sciuriwareCommented:
Could you just do      exit(0); from C++?
;JOOP!
0
 
kalle73Author Commented:
But I need to close JVM also.
0
Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

 
kalle73Author Commented:
right you are, so simple
0
 
kalle73Author Commented:
Thanks
0
 
sciuriwareCommented:
My pleasure,

;JOOP!
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.