summaryrefslogtreecommitdiffstats
path: root/services/audioflinger
diff options
context:
space:
mode:
authorEric Laurent <elaurent@google.com>2015-01-05 20:02:56 +0000
committerAndroid Git Automerger <android-git-automerger@android.com>2015-01-05 20:02:56 +0000
commit645b0192ad5d9b46b06aa06ac5670a8390d35f6f (patch)
tree29e8dae955b11910d44929c18d50ac9e1d56175a /services/audioflinger
parent51281663443ea39db9b4c6e2415343e26a6b3fb8 (diff)
parent76758100c85622c178355959e454651310ea0011 (diff)
downloadframeworks_av-645b0192ad5d9b46b06aa06ac5670a8390d35f6f.zip
frameworks_av-645b0192ad5d9b46b06aa06ac5670a8390d35f6f.tar.gz
frameworks_av-645b0192ad5d9b46b06aa06ac5670a8390d35f6f.tar.bz2
am 76758100: am 43637c2e: Merge "fix memory leak in PatchPanel"
* commit '76758100c85622c178355959e454651310ea0011': fix memory leak in PatchPanel
Diffstat (limited to 'services/audioflinger')
-rw-r--r--services/audioflinger/PatchPanel.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/services/audioflinger/PatchPanel.cpp b/services/audioflinger/PatchPanel.cpp
index 7544052..4f0c6b1 100644
--- a/services/audioflinger/PatchPanel.cpp
+++ b/services/audioflinger/PatchPanel.cpp
@@ -166,7 +166,9 @@ status_t AudioFlinger::PatchPanel::createAudioPatch(const struct audio_patch *pa
if (*handle == mPatches[index]->mHandle) {
ALOGV("createAudioPatch() removing patch handle %d", *handle);
halHandle = mPatches[index]->mHalHandle;
+ Patch *removedPatch = mPatches[index];
mPatches.removeAt(index);
+ delete removedPatch;
break;
}
}