Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

JRE Run Error

Options
  • 21-11-2007 4:20pm
    #1
    Registered Users Posts: 1,380 ✭✭✭


    For some reason, I can't run Java programs that use JOptionPane in Vista. I can compile using javac fine, and programs that run using out.print work fine, but anything using a JOptionPane just crashes with the following error:

    # An unexpected error has been detected by Java Runtime Enviroment:
    # EXCEPTION_FLT_STACK_CHECK (0xc0000092) at pc=0x0199cca9,
    # pid=3036, tid =1096
    # Java VM: Java HotSpoit(TM) Client VM (1.6.0_03-b05
    # mixedmode,sharing)
    # Problematic frame:
    # v ~RuntimeStub;:ic_miss_stub
    # An error report file with more information is saved as hs_err_pid3036.log

    Why is this happening and what is going wrong? I have the latest JRE and JDK, and I'm using Vista Business.. I'v included the error report and an example of the code that caused it

    NB: I run a dual boot with XP, and everything works fine when I use that..


Comments

  • Closed Accounts Posts: 198 ✭✭sh_o


    Looks like the c:\system32\java.exe and the C:\Program Files\Java\jre1.6.0_03\bin java and respective dll's are being mixed up.

    I would try opening a dos window, unset the Path variable and try starting your application with C:\Program Files\Java\jre1.6.0_03\bin\java.exe and then troubleshoot it further from there.


  • Moderators, Science, Health & Environment Moderators Posts: 10,079 Mod ✭✭✭✭marco_polo


    It is possible that it may be trying to run the program using java.exe from the system32 folder, although I would have expcted to see a BadClassVersionException or something like that instead of a thread dump so perhaps the first reply is right.

    To rule out this possibility, Open up a cmd window and type java -version. If you don't see something like Java HotSpot(TM) Client VM (build 1.6.0) then you will know that this is the problem.

    If it is running the incorrect JRE then it is probably because in the PATH environment variable, C:\Windows\system32 comes before C:\Program Files\Java\jdk1.6.0_03\bin

    If you change this

    PATH=C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Program Files\Java\jdk1.6.0_03\bin

    to this

    PATH=C:\Program Files\Java\jdk1.6.0_03\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem

    It might resolve the issue. (I have no idea where one would do this in Vista)


  • Registered Users Posts: 21,264 ✭✭✭✭Hobbes


    I think the problem is vista related. I have had similar issues using Virtual tables in SWT. They don't render in Vista, and crash the program.

    Looking at your crash stack the issue is here.
    =>0x0196a000 JavaThread "AWT-Windows" daemon [_thread_in_Java, id=1096]

    Your AWT code is fine. Most likely to do with how Vista renders apps now. There should be an option to change Vista to render your app the old way. try the windows forum if no one gives you help here.

    Also vista doesn't come with a JVM. So it is possible that java.exe in the System32 is due to the V6 install.


  • Moderators, Science, Health & Environment Moderators Posts: 10,079 Mod ✭✭✭✭marco_polo


    Hobbes wrote: »
    I think the problem is vista related. I have had similar issues using Virtual tables in SWT. They don't render in Vista, and crash the program.

    Looking at your crash stack the issue is here.
    =>0x0196a000 JavaThread "AWT-Windows" daemon [_thread_in_Java, id=1096]

    Your AWT code is fine. Most likely to do with how Vista renders apps now. There should be an option to change Vista to render your app the old way. try the windows forum if no one gives you help here.

    Also vista doesn't come with a JVM. So it is possible that java.exe in the System32 is due to the V6 install.

    I didn't realise that Vista doesn't have a default JVM. A quick bit of googling reveals that copying java.exe to is a part of the Java 6 installer program so that theory is out of the window.


Advertisement