diff options
author | Andy Hung <hunga@google.com> | 2015-08-28 21:26:29 +0000 |
---|---|---|
committer | Android Git Automerger <android-git-automerger@android.com> | 2015-08-28 21:26:29 +0000 |
commit | 0ea9e2761a04c4f592d854dbde2749395735fe56 (patch) | |
tree | 4d71c2c9d69d9d6e24a69e33b2deabc350eccc10 /media | |
parent | 762c713900bd764570c8fda4e238497200da66d6 (diff) | |
parent | 184ad88ddd6bbdf01e131e8e5b75bef5be67b29b (diff) | |
download | frameworks_av-0ea9e2761a04c4f592d854dbde2749395735fe56.zip frameworks_av-0ea9e2761a04c4f592d854dbde2749395735fe56.tar.gz frameworks_av-0ea9e2761a04c4f592d854dbde2749395735fe56.tar.bz2 |
am 184ad88d: am fba72ab0: am f394f121: Merge "libmedia: clear reply data for IEffect command" into klp-dev
* commit '184ad88ddd6bbdf01e131e8e5b75bef5be67b29b':
libmedia: clear reply data for IEffect command
Diffstat (limited to 'media')
-rw-r--r-- | media/libmedia/IEffect.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/media/libmedia/IEffect.cpp b/media/libmedia/IEffect.cpp index b94012a..431cf87 100644 --- a/media/libmedia/IEffect.cpp +++ b/media/libmedia/IEffect.cpp @@ -154,14 +154,14 @@ status_t BnEffect::onTransact( uint32_t cmdSize = data.readInt32(); char *cmd = NULL; if (cmdSize) { - cmd = (char *)malloc(cmdSize); + cmd = (char *)calloc(cmdSize, 1); data.read(cmd, cmdSize); } uint32_t replySize = data.readInt32(); uint32_t replySz = replySize; char *resp = NULL; if (replySize) { - resp = (char *)malloc(replySize); + resp = (char *)calloc(replySize, 1); } status_t status = command(cmdCode, cmdSize, cmd, &replySz, resp); reply->writeInt32(status); |