Projects > cpp > Issues > Bug #3022

We are migrating issue tracker of Cocos2d-x Project to Github, please create new issue there. Thanks.

Create Issue on Github

SimpleAudioEngine Leaks Memory

Bug #3022 [Closed]
kfikani 2013-10-21 21:02 . Updated almost 10 years ago


While running Instruments from Xcode to check for any memory leaks in my code, I’ve realized that the SimpleAudioEngine leaks memory. What I have in my game is a background music that I just call once and it keeps on repeating forever.

The following is my code for playing a background music:
CocosDenshion::SimpleAudioEngine::sharedEngine()->playBackgroundMusic(“themeMusic.mp3”, true);

I’ve commented out all the other code that has to do with playing sound effects and background music. I’ve attached a screenshot of the objects that leak.

Obviously when I comment out the mentioned code I get zero memory leaks.


Screen Shot 2013-08-28 at 3.05.55 PM.png - Memory Leak Screenshot (236.3 kB) kfikani, 2013-10-21 21:02 2014-10-08 02:54

Redmine issue system is closed, we are using github issue system instead.

This issue was moved to

Atom PDF

Start date:2013-10-21
Due date:
% Done:


Category:android, ios
Target version:-