Merge "Fix the arguments to memcpy." into mnc-dev
diff --git a/services/sensorservice/SensorService.cpp b/services/sensorservice/SensorService.cpp
index c7bcaef..a401145 100644
--- a/services/sensorservice/SensorService.cpp
+++ b/services/sensorservice/SensorService.cpp
@@ -1709,7 +1709,7 @@
#endif
} else if (numBytesRead == sizeof(uint32_t)) {
uint32_t numAcks = 0;
- memcpy(&numAcks, buf, sizeof(numBytesRead));
+ memcpy(&numAcks, buf, numBytesRead);
// Sanity check to ensure there are no read errors in recv, numAcks is always
// within the range and not zero. If any of the above don't hold reset
// mWakeLockRefCount to zero.