From df05f6e0ebf39c20290f1a2e3856d8c9c0de49fe Mon Sep 17 00:00:00 2001 From: zengwei2000 <102871671+zengwei2000@users.noreply.github.com> Date: Thu, 21 Dec 2023 08:24:35 +0800 Subject: [PATCH] fix the Memory leak: psp (#16016) fix the Memory leak: psp Signed-off-by: zengwei zengwei1@uniontech.com Signed-off-by: zengwei zengwei1@uniontech.com --- audio/drivers/psp_audio.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/audio/drivers/psp_audio.c b/audio/drivers/psp_audio.c index abd5ea09cd..2bbdd3fee8 100644 --- a/audio/drivers/psp_audio.c +++ b/audio/drivers/psp_audio.c @@ -136,7 +136,10 @@ static void *psp_audio_init(const char *device, return NULL; if ((port = configureAudio(rate)) < 0) + { + free(psp); return NULL; + } #if defined(ORBIS) sceAudioOutInit();