I´m getting the crash below but can't track in in VS2010 because it only occurs in the release code!
In debug mode it never crashes.
The crash seems to happen in CDMFLoader, in a call to string, but I don´t know how to locate it more exactly with the information listed.
I added exception handling to getMesh, which calls CDMFLoader, but it still crashes...
Any ideas would be appreciated.
Fatal error: 01:00041060 : Irrlicht.dll
0001:00040fe0 ??$?0D@?$string@DV?$irrAllocator@D@core@irr@@@core@irr@@QAE@QBDI@Z 10041fe0 f i CDMFLoader.obj
0001:00041090 ??$split@V?$array@V?$string@DV?$irrAllocator@D@core@irr@@@core@irr@@V?$irrAllocator@V?$string@DV?$irrAllocator@D@core@irr@@@core@irr@@@23@@core@irr@@@?$string@DV?$irrAllocator@D@core@irr@@@core@irr@@QBEIAAV?$array@V?$string@DV?$irrAllocator@D@core@irr@@@core@irr@@V?$irrAllocator@V?$string@DV?$irrAllocator@D@core@irr@@@core@irr@@@23@@12@QBDI_N2@Z 10042090 f i CDMFLoader.obj
[fixed]Occasional exception crash in CDMFLoader
Re: Occasional exception crash in CDMFLoader
Can you post the model somewhere? Might be worth checking in debug if valgrind sees any problems.
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
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Re: Occasional exception crash in CDMFLoader
Not sure it is any of the models, as when compiled with the debug setting it never crashes.
I wonder if its a string allocation failing, it happens after about 20 - 30 reload cycles, going from opengl to d3d... and also when set to D3D only.
Only crashes when one particular scene is loaded so it must be something in that scene that causes the crash after so many cycles...
I wonder if its a string allocation failing, it happens after about 20 - 30 reload cycles, going from opengl to d3d... and also when set to D3D only.
Only crashes when one particular scene is loaded so it must be something in that scene that causes the crash after so many cycles...
Re: Occasional exception crash in CDMFLoader
Got the bugger!! After hundreds of scene reloads it eventually crashed in a different place, namely getNextToken, from CXMeshFileLoader
I was using a small .x camera, two of them, and converting them to .obj removed the crash event.
The offending .x file is available here:- http://www.sendspace.com/file/rxgdhc
I was using a small .x camera, two of them, and converting them to .obj removed the crash event.
The offending .x file is available here:- http://www.sendspace.com/file/rxgdhc
Re: Occasional exception crash in CDMFLoader
Anyone interested in making the .x loader more crash proof?
The obj loader can also be crashed by incorrect obj files... should that be fixed?
The obj loader can also be crashed by incorrect obj files... should that be fixed?
-
- Admin
- Posts: 14143
- Joined: Wed Apr 19, 2006 9:20 pm
- Location: Oldenburg(Oldb), Germany
- Contact:
Re: Occasional exception crash in CDMFLoader
Works for me. Are you sure there's a problem with that file?
Re: Occasional exception crash in CDMFLoader
Well, if I use the obj version it never crashes, if I use the .x version, a crash occurs about every twenty scene reloads....
maybe there is some weird compiler issue at play, or a timing issue. It never crashes with the debug code... makes it a little complex to debug!
I also have some obj files that crash the obj loader every time. Easy to protect in the obj loader, but adds overhead of course...
will take a look at it and post again when I know more
maybe there is some weird compiler issue at play, or a timing issue. It never crashes with the debug code... makes it a little complex to debug!
I also have some obj files that crash the obj loader every time. Easy to protect in the obj loader, but adds overhead of course...
will take a look at it and post again when I know more
Re: Occasional exception crash in CDMFLoader
Otaka posted the bug fix to this issue:
Code: Select all
u16 CXMeshFileLoader::readBinWord(){
#ifdef __BIG_ENDIAN__
const u16 tmp = os::Byteswap::byteswap(*(u16 *)P);
#else
//START PATCH
if ( End-P <=0 ) // If pointer at end or passed end of file
return -1;
//END PATCH
const u16 tmp = *(u16 *)P;
#endif
P += 2;
return tmp;
}