debug with -DWANT_DEBUG

tigital tigital at mac.com
Fri Aug 16 11:31:08 EDT 2002


me again,

...since getting through the last font loading problem I was having, 
I had moved on to sound file loading, but unfortunately I'm getting 
some weird malloc problems at different points in the font loading 
code!  I looked at the unix.cpp file (which contains the vm_malloc 
calls that seem to cause the problem), and discovered a define 
WANT_DEBUG, which seems to open up new code for debugging the kind of 
problems I'm seeing...

So, my question is, what does this really tell me?  How do I 
interpret the output (ie. if, at the point of the crash, it says:

MALLOC: 
/Users/tigital/Desktop/programming/freespace2/src/graphics/font.cpp:834 
1744 bytes
MALLOC: 
/Users/tigital/Desktop/programming/freespace2/src/graphics/font.cpp:848 
7722 bytes
MALLOC: 
/Users/tigital/Desktop/programming/freespace2/src/graphics/font.cpp:870 
16384 bytes
MALLOC: 
/Users/tigital/Desktop/programming/freespace2/src/graphics/font.cpp:871 
436 bytes
MALLOC: 
/Users/tigital/Desktop/programming/freespace2/src/graphics/font.cpp:872 
436 bytes
MALLOC: 
/Users/tigital/Desktop/programming/freespace2/src/graphics/font.cpp:827 
669 bytes
MALLOC: 
/Users/tigital/Desktop/programming/freespace2/src/graphics/font.cpp:834 
1520 bytes
MALLOC: 
/Users/tigital/Desktop/programming/freespace2/src/graphics/font.cpp:848 
24912 bytes

...does this mean that the problem is the last printed malloc, or the 
next one that would be printed?

sorry for being such a newbie, but at least I'm learning a bunch of stuff!

l8r,
jamie



More information about the freespace2 mailing list