mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-10-01 14:58:14 +00:00
Smash some memory leaks
This commit is contained in:
1 parent
338a73472b
commit
8277d901e2
3 files changed
+33
-20
No files matched your search
+6
-2
@@ -42,6 +42,7 @@
|
||||
MetaFileSystem pspFileSystem;
|
||||
ParamSFOData g_paramSFO;
|
||||
static CoreParameter coreParameter;
|
||||
static PSPMixer *mixer;
|
||||
|
||||
bool PSP_Init(const CoreParameter &coreParam, std::string *error_string)
|
||||
{
|
||||
@@ -54,7 +55,8 @@ bool PSP_Init(const CoreParameter &coreParam, std::string *error_string)
|
||||
|
||||
if (coreParameter.enableSound)
|
||||
{
|
||||
host->InitSound(new PSPMixer());
|
||||
mixer = new PSPMixer();
|
||||
host->InitSound(mixer);
|
||||
}
|
||||
|
||||
// Init all the HLE modules
|
||||
@@ -100,10 +102,12 @@ void PSP_Shutdown()
|
||||
if (coreParameter.enableSound)
|
||||
{
|
||||
host->ShutdownSound();
|
||||
delete mixer;
|
||||
mixer = 0;
|
||||
}
|
||||
__KernelShutdown();
|
||||
HLEShutdown();
|
||||
Memory::Shutdown() ;
|
||||
Memory::Shutdown();
|
||||
currentCPU = 0;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user