Multiple processes after closing program

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
Asimov
Posts: 246
Joined: Thu Dec 04, 2014 7:41 pm
Contact:

Multiple processes after closing program

Post by Asimov »

Hi,

I noticed that sometimes when an irrlicht program stops it leaves the process in memory. So it seems it is not cleaning up after itself.

I obviously run

Code: Select all

    device->drop();
    return 0;
after the main game loop and I thought this was responsible for cleaning up the device.
I wonder if I should have something in my classes that should be dropped in the deconstructor or something.

Image
CuteAlien
Admin
Posts: 9734
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: Multiple processes after closing program

Post by CuteAlien »

Ok, that is very strange. Are you using VisualStudio? I remember that allows creating projects in different ways - console, windows... and some more I think. Irrlicht has to be a console application. I suspect if you use one of the other it might be possible that there is still something running. Sorry, I've never investigated too much into the differences there, so not really sure if that is the reason. For a normal console application calling return in main() is already sufficient to quit the process.
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Asimov
Posts: 246
Joined: Thu Dec 04, 2014 7:41 pm
Contact:

Re: Multiple processes after closing program

Post by Asimov »

Hi CuteAlien,
Ok, that is very strange. Are you using VisualStudio?
No I am using Code::blocks. I am thinking it may have been because it crashed and locked the process or something.
I will have to do a proper investigation after a reboot and let you know if it happens every time.

My learning process will be a bit slower after tomorrow as I am back to work grrr.
CuteAlien
Admin
Posts: 9734
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: Multiple processes after closing program

Post by CuteAlien »

I remember one problem with C::B on Windows. When you close the console output window instead of the application then it got into some strange state when run from the debugger. It doesn't quit the application then really.
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Post Reply