summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNaveen Leekha <leekha@google.com>2015-09-24 22:20:59 +0000
committerAndroid Git Automerger <android-git-automerger@android.com>2015-09-24 22:20:59 +0000
commit571e27e20e30560985d7c3a3ba8885693695b0fc (patch)
treefcd0ee0700102b2f7c11df2c9588ec7e5347b757
parente35c7d65bb3c226fe3c5fc5e3933f64f0963eaeb (diff)
parente889592e33891c9b88ff6ba655426118f8ef12ee (diff)
downloadframeworks_native-571e27e20e30560985d7c3a3ba8885693695b0fc.zip
frameworks_native-571e27e20e30560985d7c3a3ba8885693695b0fc.tar.gz
frameworks_native-571e27e20e30560985d7c3a3ba8885693695b0fc.tar.bz2
am e889592e: am 73887c08: am b414255f: Initialize local variables to avoid data leak
* commit 'e889592e33891c9b88ff6ba655426118f8ef12ee': Initialize local variables to avoid data leak
-rw-r--r--libs/gui/IGraphicBufferProducer.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/libs/gui/IGraphicBufferProducer.cpp b/libs/gui/IGraphicBufferProducer.cpp
index d7a7885..2118c92 100644
--- a/libs/gui/IGraphicBufferProducer.cpp
+++ b/libs/gui/IGraphicBufferProducer.cpp
@@ -389,7 +389,7 @@ status_t BnGraphicBufferProducer::onTransact(
CHECK_INTERFACE(IGraphicBufferProducer, data, reply);
sp<GraphicBuffer> buffer = new GraphicBuffer();
data.read(*buffer.get());
- int slot;
+ int slot = 0;
int result = attachBuffer(&slot, buffer);
reply->writeInt32(slot);
reply->writeInt32(result);