Memory Leak? [shaders.dll] - Fixed ^^ [message #413889] |
Sun, 13 December 2009 03:01 |
Tunaman
Messages: 1190 Registered: January 2005
Karma: 2
|
General (1 Star) |
|
|
Hiya, I've been messing around in shaderhud.cpp and changing some stuff, and I've noticed that there's a file in my renegade directory called "memleak_shaders<number here>.log" containing some information I'm not sure what to make of. Could someone please help me fix what's going on?
I don't believe I have added anything to shaderhud.cpp that would even allocate any memory so I don't think that I've caused this problem with the code I've added.. It might be something I haven't thought about though..
I'm using Visual C++ Express 2008 to compile with btw, if that helps any.
Here's an except from one of the files:
Toggle Spoiler
-------------------------------------------------------------------------------- --------------------------------------------------
| Memory leak report for: 12/13/2009 01:20:29 |
-------------------------------------------------------------------------------- --------------------------------------------------
3 memory leaks found:
Alloc. Addr Size Addr Size BreakOn BreakOn
Number Reported Reported Actual Actual Unused Method Dealloc Realloc Allocated by
------ ---------- ---------- ---------- ---------- ---------- -------- ------- ------- ---------------------------------------------------
000067 0x02F03FB4 0x00000010 0x02F03FA4 0x00000030 0x00000004 new N N engine_3d.cpp(02030)::Font3DDataClass::Minimize_Font_Image
000066 0x02ED8924 0x00000010 0x02ED8914 0x00000030 0x00000004 new N N engine_3d.cpp(02030)::Font3DDataClass::Minimize_Font_Image
000065 0x02D4B974 0x00000010 0x02D4B964 0x00000030 0x00000004 new N N engine_3d.cpp(02030)::Font3DDataClass::Minimize_Font_Image
Edit: Looks like its an error with my compiler(unless the normal shaders.dll has a mem leak) or something.. I just compiled a clean version of shaders.dll and it still has memory leaks.
[Updated on: Sun, 13 December 2009 22:50] Report message to a moderator
|
|
|
Re: Memory Leak? [shaders.dll] [message #413919 is a reply to message #413889] |
Sun, 13 December 2009 14:04 |
|
danpaul88
Messages: 5795 Registered: June 2004 Location: England
Karma: 0
|
General (5 Stars) |
|
|
Don't compile in debug mode if you don't want debugging files to be created at runtime... also your game will run a LOT faster if you use non-debug dll files.
As for the leaks, I wouldn't worry about it, it's probably just stuff that didn't get cleaned up properly at shutdown.
[Updated on: Sun, 13 December 2009 14:05] Report message to a moderator
|
|
|
Re: Memory Leak? [shaders.dll] [message #413952 is a reply to message #413889] |
Sun, 13 December 2009 18:18 |
Tunaman
Messages: 1190 Registered: January 2005
Karma: 2
|
General (1 Star) |
|
|
Yeah; I do like the debug information while I'm still working on my dll(I'm usually pretty careful but in case I forget to clean something up on my end).
Yeah, the memory leaks didn't seem like a big deal since its only 2-3 items that don't get deleted per instance of ren it seems. I was just wondering if anyone knew a fix. ^^
Thanks for the quick reply!
|
|
|
Re: Memory Leak? [shaders.dll] [message #413968 is a reply to message #413952] |
Sun, 13 December 2009 21:41 |
|
saberhawk
Messages: 1068 Registered: January 2006 Location: ::1
Karma: 0
|
General (1 Star) |
|
|
Tunaman wrote on Sun, 13 December 2009 20:18 | Yeah; I do like the debug information while I'm still working on my dll(I'm usually pretty careful but in case I forget to clean something up on my end).
Yeah, the memory leaks didn't seem like a big deal since its only 2-3 items that don't get deleted per instance of ren it seems. I was just wondering if anyone knew a fix. ^^
Thanks for the quick reply!
|
There's an issue with 3.4.4's SurfaceClass constructor where the reference count isn't being initialized to 1 iirc.
|
|
|
|