Running Swing application from IDE fails with exit code -1073740791, but starts from JAR artifact

Answered

Hello,

 

I have a following problem with IDEA.

When I run my Swing application from IDE, there is a message saying "Process finished with exit code -1073740791 (0xC0000409)".

Suprisingly, when I created a jar artifact, rebuilt the project module and then run the jar from outside the IDE, everything worked and application started.

Maybe this could be an issue with IDEA.

Now I use IntelliJ IDEA 2016.3.4 and Oracle JDK 1.8.0 u121.

I have tried IDEA 2016.3.3 and JDK 1.8.0 u111 and u112 and there was the same problem.

 

Thanks in advance for your help. Greetings.

 

0
11 comments
Avatar
Permanently deleted user

In my case application starts and works fine but after I close the application Windows shows me the crash dialog for "Java(TM) Platform SE binary" and error code is shown in IDEA console:

Process finished with exit code -1073741819 (0xC0000005)

idea.log is clean and IDEA itself seems fine.

java version "1.8.0_121"
Java(TM) SE Runtime Environment (build 1.8.0_121-b13)
Java HotSpot(TM) 64-Bit Server VM (build 25.121-b13, mixed mode)

Forgot to mention that my app is Java FX based.

0
Avatar
Permanently deleted user

Very same application launched from command line like "java -jar ..." works fine. I'm not sure that downgrading video driver to make IDE work is a good idea.

0

Please give it a try.

0

So I tried to test things connected with graphics drivers. I have Nvidia GTX 960M laptop card.

I removed the newest Nvidia driver, restarted the system and waited for default Microsoft driver to install automatically.

After starting Intellij IDEA version 2016.3.4 I ran my program. IDEA console displayed and GUI showed. After finishing the program application returned exit code 0 and so everything went correctly.

Maybe Nvidia should correct this mistake in further driver releases, because it is always good to have the latest drivers, and sometimes I play games.

0

Thanks for the information.

0

I have some additional information, if you want to use a bit newer driver than the default one from Microsoft.

The newest driver from Nvidia is 378.49. With this driver running Swing applications from IDEA will cause the problem.

I went through few drivers and it seems that the last one which works fine is 376.33 (it is a release just before the newest one, so not to old).

So the best solution by now is to install this driver (376.33) and wait for a new correct release. To avoid auto updating, you can install the main driver and physx software only (without experience software).

0

Downgrading to 376.33 is exactly what is suggested in the thread I've linked above.

0

OK! I didn't notice, thanks.

0

Nvidia Geforce 378.57 Hot Fix Drivers:

- Fixed crash in Minecraft and some other Java-based titles

http://www.guru3d.com/files-details/geforce-378-57-hotfix-driver-download.html

0

Hello,

There is a new version of the Nvidia driver (378.66).
Comparing to the driver form guru3d - you have the driver from original vendor and with newest fixes. :)
I have tested this version on my laptop (with GeForce GTX 960M).
On IntelliJ IDEA 2016.3.4 with a Swing application: it starts, works and finishes with exit code 0 on the environment console.
It seems to be ok now.

Here is what Nvidia changed since the buggy (378.49) version of their driver:
(taken from http://us.download.nvidia.com/Windows/378.66/378.66-win10-win8-win7-notebook-release-notes.pdf, page 15)
[Minecraft]: Java SE Binary crashes pointing to nvinitx.dll. [200274582]

0

Please sign in to leave a comment.