summaryrefslogtreecommitdiffstats
path: root/gatekeeperd
diff options
context:
space:
mode:
authorAndres Morales <anmorales@google.com>2015-07-07 10:28:15 -0700
committerAndres Morales <anmorales@google.com>2015-07-08 20:33:36 +0000
commitfef908e5a50a4026bb94edabb8f500a959b9ed0e (patch)
tree0fca87cf012522110caa3ec7b38f86cca65b340f /gatekeeperd
parent4dd2982dd31d43e905f6792201c404a2e549ca17 (diff)
downloadsystem_core-fef908e5a50a4026bb94edabb8f500a959b9ed0e.zip
system_core-fef908e5a50a4026bb94edabb8f500a959b9ed0e.tar.gz
system_core-fef908e5a50a4026bb94edabb8f500a959b9ed0e.tar.bz2
[gatekeeperd] fix use of uninitialized memory
Bug: 22319772 Change-Id: I3cb83389f11e54867aca132de48a3f6407b7eaf3
Diffstat (limited to 'gatekeeperd')
-rw-r--r--gatekeeperd/gatekeeperd.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/gatekeeperd/gatekeeperd.cpp b/gatekeeperd/gatekeeperd.cpp
index 6622df9..c91b300 100644
--- a/gatekeeperd/gatekeeperd.cpp
+++ b/gatekeeperd/gatekeeperd.cpp
@@ -50,6 +50,8 @@ class GateKeeperProxy : public BnGateKeeperService {
public:
GateKeeperProxy() {
int ret = hw_get_module_by_class(GATEKEEPER_HARDWARE_MODULE_ID, NULL, &module);
+ device = NULL;
+
if (ret < 0) {
ALOGW("falling back to software GateKeeper");
soft_device.reset(new SoftGateKeeperDevice());