bophi
20-07-2009 01:56:48
Hi,
first I want to thank you for your work, great job!
But maybe there is still one memory leak left using the multithreaded version.
I use VC9 / OGRE 1.6.2 / OgreOggSound 1.09 compiled against BOOST 1.39 and OpenAL 1.1.
All works fine except the one memory leak per created sound. Whether the sound is streamed or not.
I figured out that the memory leak is a string that is holding the path to the sound file.
The first time the memory address shows up is in:
I guess this is where it should be deleted:
first I want to thank you for your work, great job!
But maybe there is still one memory leak left using the multithreaded version.
I use VC9 / OGRE 1.6.2 / OgreOggSound 1.09 compiled against BOOST 1.39 and OpenAL 1.1.
All works fine except the one memory leak per created sound. Whether the sound is streamed or not.
I figured out that the memory leak is a string that is holding the path to the sound file.
The first time the memory address shows up is in:
OgreOggISound* OgreOggSoundManager::createSound(const std::string& name, const std::string& file, bool stream, bool loop, bool preBuffer)
{
//mFileName will later be the memory leak
fo->mFileName = file; // Filename to register
}
I guess this is where it should be deleted:
void OgreOggSoundManager::processQueuedSounds()
{
// Delete struct
(*i)->mFile.setNull();
// (*i)->mFileName = "DELETE ME";
// If I do this I can read DELETE ME in the output Window
OGRE_FREE((*i), Ogre::MEMCATEGORY_GENERAL);
}
Detected memory leaks!
Dumping objects ->
{148983} normal block at 0x0634DA40, 48 bytes long.
Data: <DELETE ME \level> 44 45 4C 45 54 45 20 4D 45 00 5C 6C 65 76 65 6C
Object dump complete.
[/list:u]
Do you have any ideas what could cause this?
Regards bophi