This forum has been archived. Please start a new discussion on GitHub.

Waitforshutdown blocks my server

Hello everyone,

I'm developping a server application with a GUI in C++ using Ice. I have created a class that extends of Ice::Application and contains all the ICE side. The thing is that an instance of that class hangs the main thread (cause the method ic->waitforshutdown) so the GUI windows can't dispatch any more event and the application remain blocked.

How can i solve this problem? there is any othe method instead of waitforshutdown to keep the communicator and not block the application?

should i call the instance of ice::application class in a new thread?

thanks in advance


  • matthew
    matthew NL, Canada
    Its probably better not to use Ice::Application at all in this case. Look at demo/Ice/minimal to see an example that does not use Ice::Application.