tags:

views:

72

answers:

1

I am calling a C process from my Java program, and ending that C process using exit (0).

On Windows machine, under certain conditions it is opening a pop-up window telling me that "Test.exe has encountered a problem and needs to close. We are sorry for the inconvenience."

Does anyone have a guess why this problem is coming around? I want a clean shutdown without any window being opened.

I have used below alternatives also to close, with the same result:

exit(EXIT_SUCESS);

and

return 0;
+4  A: 

The exit or return isnt likely to be the issue - the problem is a memory overrun etc. within the exe. You need to debug that when the problem happens.

Ruben Bartelink