Login  Register

Re: Infinite loop hanging app when working with threads

Posted by Alberto Martins on Jun 28, 2016; 11:04pm
URL: https://forum.jogamp.org/Infinite-loop-hanging-app-when-working-with-threads-tp4036849p4036859.html

Hi, the line it's stuck is:

if(!shouldStop) {
                        dispatchMessages.run();
                    }

This is inside a do ... while(!shouldStop).

I ended up resolving my issue by placing a try catch block around the window.setVisible(true) call and forcibly calling window.destroy on the catch block(if i don't destroy the window the app still enters the infinite loop).

Still think there is something weird going on with the API and this is not exactly the cleanest way out but for now it works! :)