Merge "Fix potential format string vulnerability"

This commit is contained in:
chh 2014-11-25 01:04:09 +00:00 committed by Gerrit Code Review
commit 45aa022710

View File

@ -617,12 +617,9 @@ Vector<Sensor> SensorService::getSensorList()
if (canAccessSensor(sensor)) {
accessibleSensorList.add(sensor);
} else {
String8 infoMessage;
infoMessage.appendFormat(
"Skipped sensor %s because it requires permission %s",
sensor.getName().string(),
sensor.getRequiredPermission().string());
ALOGI(infoMessage.string());
ALOGI("Skipped sensor %s because it requires permission %s",
sensor.getName().string(),
sensor.getRequiredPermission().string());
}
}
return accessibleSensorList;