summaryrefslogtreecommitdiffstats
path: root/libs
diff options
context:
space:
mode:
authorNaveen Leekha <leekha@google.com>2015-09-24 22:04:48 +0000
committerAndroid Git Automerger <android-git-automerger@android.com>2015-09-24 22:04:48 +0000
commit18165848e86feab8656bfdac3173bccf45a9a6df (patch)
treeeba9313a39e17cd826f015e0421f2de5368fc11d /libs
parentb414255f53b560a06e642251535b019327ba0d7b (diff)
parente2c4f4fb8b34e36a4f2760f3812c942604cabfb6 (diff)
downloadframeworks_native-18165848e86feab8656bfdac3173bccf45a9a6df.zip
frameworks_native-18165848e86feab8656bfdac3173bccf45a9a6df.tar.gz
frameworks_native-18165848e86feab8656bfdac3173bccf45a9a6df.tar.bz2
am e2c4f4fb: am c1e6fbb5: Initialize local variables to avoid data leak
* commit 'e2c4f4fb8b34e36a4f2760f3812c942604cabfb6': Initialize local variables to avoid data leak
Diffstat (limited to 'libs')
-rw-r--r--libs/gui/IGraphicBufferProducer.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/libs/gui/IGraphicBufferProducer.cpp b/libs/gui/IGraphicBufferProducer.cpp
index dd9db33..4f7b0d3 100644
--- a/libs/gui/IGraphicBufferProducer.cpp
+++ b/libs/gui/IGraphicBufferProducer.cpp
@@ -304,7 +304,7 @@ status_t BnGraphicBufferProducer::onTransact(
uint32_t h = data.readInt32();
uint32_t format = data.readInt32();
uint32_t usage = data.readInt32();
- int buf;
+ int buf = 0;
sp<Fence> fence;
int result = dequeueBuffer(&buf, &fence, async, w, h, format, usage);
reply->writeInt32(buf);
@@ -371,7 +371,7 @@ status_t BnGraphicBufferProducer::onTransact(
} break;
case QUERY: {
CHECK_INTERFACE(IGraphicBufferProducer, data, reply);
- int value;
+ int value = 0;
int what = data.readInt32();
int res = query(what, &value);
reply->writeInt32(value);