summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDianne Hackborn <>2009-03-25 16:21:55 -0700
committerThe Android Open Source Project <initial-contribution@android.com>2009-03-25 16:21:55 -0700
commitc3aa00b29fd9ab9b06a2bd675dac404970acb477 (patch)
tree313c44432ddf6057c24f1ca0dbe64593e7ba8205
parent749c63dbff0ab66223f30af1bad4ca56bd26d5d2 (diff)
downloadframeworks_native-c3aa00b29fd9ab9b06a2bd675dac404970acb477.zip
frameworks_native-c3aa00b29fd9ab9b06a2bd675dac404970acb477.tar.gz
frameworks_native-c3aa00b29fd9ab9b06a2bd675dac404970acb477.tar.bz2
Automated import from //branches/master/...@142771,142771
-rw-r--r--libs/ui/EventHub.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/libs/ui/EventHub.cpp b/libs/ui/EventHub.cpp
index 3b29b09..7c2fc8e 100644
--- a/libs/ui/EventHub.cpp
+++ b/libs/ui/EventHub.cpp
@@ -245,6 +245,7 @@ EventHub::device_t* EventHub::getDevice(int32_t deviceId) const
int32_t id = deviceId & ID_MASK;
if (id >= mNumDevicesById || id < 0) return NULL;
device_t* dev = mDevicesById[id].device;
+ if (dev == NULL) return NULL;
if (dev->id == deviceId) {
return dev;
}