Camera: check HIDL transaction ret value am: 73d0374fcb

am: ac47b2570e

Change-Id: I890081fbd9d3885bd4c2be747a459cb0d4e7873e
gugelfrei
Yin-Chia Yeh 7 years ago committed by android-build-merger
commit 003e3fb00f

@ -202,12 +202,17 @@ bool CameraProviderManager::supportSetTorchMode(const std::string &id) {
for (auto& provider : mProviders) {
auto deviceInfo = findDeviceInfoLocked(id);
if (deviceInfo != nullptr) {
provider->mInterface->isSetTorchModeSupported(
auto ret = provider->mInterface->isSetTorchModeSupported(
[&support](auto status, bool supported) {
if (status == Status::OK) {
support = supported;
}
});
if (!ret.isOk()) {
ALOGE("%s: Transaction error checking torch mode support '%s': %s",
__FUNCTION__, provider->mProviderName.c_str(), ret.description().c_str());
}
break;
}
}
return support;

Loading…
Cancel
Save