Camera1: Fix enable shutter sound command error handling.
Return the error codes from calls to enableShutterSound to the caller,
and don't call the HAL with the enable shutter sound command.
Change-Id: Ibe4943bd1cd0fcd1832fd904f12dd2f78fec06a5
diff --git a/services/camera/libcameraservice/CameraClient.cpp b/services/camera/libcameraservice/CameraClient.cpp
index 562384d..c9c816a 100644
--- a/services/camera/libcameraservice/CameraClient.cpp
+++ b/services/camera/libcameraservice/CameraClient.cpp
@@ -608,11 +608,9 @@
} else if (cmd == CAMERA_CMD_ENABLE_SHUTTER_SOUND) {
switch (arg1) {
case 0:
- enableShutterSound(false);
- break;
+ return enableShutterSound(false);
case 1:
- enableShutterSound(true);
- break;
+ return enableShutterSound(true);
default:
return BAD_VALUE;
}