diff options
author | Dennis Cagle <d-cagle@codeaurora.org> | 2017-08-03 15:23:53 -0700 |
---|---|---|
committer | Shuzhen Wang <shuzhenwang@google.com> | 2017-08-08 16:51:06 -0700 |
commit | c0610d4f9af107a40b0f57c344e764d2abc84159 (patch) | |
tree | f04a4773064d4e85a9204b995bf28ac87d43a318 | |
parent | b18714d03f357e1a12a115a18816072e6700493e (diff) | |
download | bullhead-c0610d4f9af107a40b0f57c344e764d2abc84159.tar.gz |
QCamera2/HAL3: correct mutex lock/unlock sequence
Bug: 36716469
CRs-Fixed: 2053027
Change-Id: I6699c3682eec419fb6efb0583e9909e5739476a0
(cherry picked from commit a5eedde871c8e87784014e541c4aec247e954dc2)
-rw-r--r-- | camera/QCamera2/HAL3/QCamera3HWI.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/camera/QCamera2/HAL3/QCamera3HWI.cpp b/camera/QCamera2/HAL3/QCamera3HWI.cpp index 26c9acd..02d5f37 100644 --- a/camera/QCamera2/HAL3/QCamera3HWI.cpp +++ b/camera/QCamera2/HAL3/QCamera3HWI.cpp @@ -1837,6 +1837,7 @@ int QCamera3HardwareInterface::configureStreamsPerfLocked( newStream->max_buffers = MAX_INFLIGHT_REPROCESS_REQUESTS; } else { ALOGE("%s: Error, Unknown stream type", __func__); + pthread_mutex_unlock(&mMutex); return -EINVAL; } @@ -3595,6 +3596,7 @@ no_error: if(ADD_SET_PARAM_ENTRY_TO_BATCH(mParameters, CAM_INTF_META_FRAME_NUMBER, request->frame_number)) { ALOGE("%s: Failed to set the frame number in the parameters", __func__); + pthread_mutex_unlock(&mMutex); return BAD_VALUE; } } |