summaryrefslogtreecommitdiffstats
path: root/libcamera
diff options
context:
space:
mode:
authorSimon Wilson <simonwilson@google.com>2010-10-26 10:34:07 -0700
committerSimon Wilson <simonwilson@google.com>2010-10-26 10:40:46 -0700
commitd731c7875855b8d204f2fd2fd2e80a4646602165 (patch)
tree76892fe2b6c1efb020e78db8503b2b60d39d1f4e /libcamera
parent3c4232c3b525d78ccb1e1058ef6f425afc9ebe55 (diff)
downloaddevice_samsung_crespo-d731c7875855b8d204f2fd2fd2e80a4646602165.zip
device_samsung_crespo-d731c7875855b8d204f2fd2fd2e80a4646602165.tar.gz
device_samsung_crespo-d731c7875855b8d204f2fd2fd2e80a4646602165.tar.bz2
libcamera: don't invoke callback when startPreview fails
startPreview() of SecCameraHWInterface.cpp should not invoke a callback when startPreview fails. It will cause a deadlock. CameraService was holding mLock in any method call from applications. In those calls, camera HAL must not invoke a callback and it also needs to acquire the mLock. startPreview should just return an error and apps will get an exception. Change-Id: I89f3a614a0efa56abcdde17ba5dd5f7a5e54911c
Diffstat (limited to 'libcamera')
-rw-r--r--libcamera/SecCameraHWInterface.cpp3
1 files changed, 0 insertions, 3 deletions
diff --git a/libcamera/SecCameraHWInterface.cpp b/libcamera/SecCameraHWInterface.cpp
index 27c30cc..509f4fd 100644
--- a/libcamera/SecCameraHWInterface.cpp
+++ b/libcamera/SecCameraHWInterface.cpp
@@ -628,9 +628,6 @@ status_t CameraHardwareSec::startPreview()
if (ret < 0) {
LOGE("ERR(%s):Fail on mSecCamera->startPreview()", __func__);
- if (mMsgEnabled & CAMERA_MSG_ERROR) {
- mNotifyCb(CAMERA_MSG_ERROR, -2, 0, mCallbackCookie);
- }
return -1; //UNKNOWN_ERROR;
}