Strange error on Close app

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
Bear_130278
Posts: 237
Joined: Mon Jan 16, 2006 1:18 pm
Location: Odessa,Russian Federation

Strange error on Close app

Post by Bear_130278 »

First-chance exception in Trollbrad.exe (IRRLICHT.DLL): 0xC0000005: Access Violation.
The thread 0x75C has exited with code -1073741819 (0xC0000005).
The program 'Trollbrad.exe' has exited with code -1073741819 (0xC0000005).

I receive this error when exiting the App over Alt+F4 or Just closing the window by cross, but if i close the console window first, there is no error.
I wonder, if anybody experienced the same error?
Do you like VODKA???
Image
Image
JP
Posts: 4526
Joined: Tue Sep 13, 2005 2:56 pm
Location: UK
Contact:

Post by JP »

maybe the command prompt kills the process when closed but closing the window just exits out of your render loop so it's probably crashing somewhere after your render loop but before returning from main. what's the code after your render loop?

And i suppose a better question would have been... what's your callstack?? run in debug mode and you can find out exactly what line of code crashed ;)
Image Image Image
rogerborg
Admin
Posts: 3590
Joined: Mon Oct 09, 2006 9:36 am
Location: Scotland - gonnae no slag aff mah Engleesh
Contact:

Re: Strange error on Close app

Post by rogerborg »

Bear_130278 wrote:I wonder, if anybody experienced the same error?
We could, if you'd provide source code. ;)
Please upload candidate patches to the tracker.
Need help now? IRC to #irrlicht on irc.freenode.net
How To Ask Questions The Smart Way
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Post by hybrid »

Could be that killing the terminal will just remove the process, without cleaning up everything. Exiting via ALT-F4 or exit button does so, though, so double drop() will show up for sure. Just make sure you don't drop things you shouldn't and it should work without problems.
Bear_130278
Posts: 237
Joined: Mon Jan 16, 2006 1:18 pm
Location: Odessa,Russian Federation

Post by Bear_130278 »

Core.device->drop();
That was it 8)))

10x a lot guys 8)
Do you like VODKA???
Image
Image
Munger
Posts: 28
Joined: Sun Mar 04, 2007 11:39 am
Location: Tokyo

Post by Munger »

For anyone else who gets an error like this, errors on exit under windows are more than likely caused by memory handling errors. The problem is probably in your code. Writing into invalid areas of memory are a common cause: writing outside the bounds of an array, writing into deallocated or unallocated memory, double-deletions etc.

They can be really confusing when you first see them because they quite often won't crash when the actual mistake was made. The crash comes when all the code 'out the back' tries to clean up your memory and finds something a little funny. This means that it won't even seem like the problem is in your code and the break point will be deep inside some system call.

I know now I've said this, someone will come along and point out all the lies and inconsistencies in what I've said. But I hope it helps someone somewhere :-)
Post Reply