Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 0cfad575 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Camera: fix legacy device CTS failure" into oc-mr1-dev

parents 3e4e9e23 daf20731
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -504,12 +504,18 @@ public class CameraDeviceUserShim implements ICameraDeviceUser {
        if (mLegacyDevice.isClosed()) {
            String err = "Cannot end configure, device has been closed.";
            Log.e(TAG, err);
            synchronized(mConfigureLock) {
                mConfiguring = false;
            }
            throw new ServiceSpecificException(ICameraService.ERROR_DISCONNECTED, err);
        }

        if (operatingMode != ICameraDeviceUser.NORMAL_MODE) {
            String err = "LEGACY devices do not support this operating mode";
            Log.e(TAG, err);
            synchronized(mConfigureLock) {
                mConfiguring = false;
            }
            throw new ServiceSpecificException(ICameraService.ERROR_ILLEGAL_ARGUMENT, err);
        }