summaryrefslogtreecommitdiffstats
path: root/services
diff options
context:
space:
mode:
Diffstat (limited to 'services')
-rw-r--r--services/camera/libcameraservice/camera2/CallbackProcessor.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/services/camera/libcameraservice/camera2/CallbackProcessor.cpp b/services/camera/libcameraservice/camera2/CallbackProcessor.cpp
index 5fa84e0..05c0abe 100644
--- a/services/camera/libcameraservice/camera2/CallbackProcessor.cpp
+++ b/services/camera/libcameraservice/camera2/CallbackProcessor.cpp
@@ -182,6 +182,13 @@ bool CallbackProcessor::threadLoop() {
}
do {
+ Mutex::Autolock l(mInputMutex);
+ if (mCallbackStreamId == NO_STREAM) {
+ ALOGV("%s: Camera %d:No stream is available"
+ , __FUNCTION__, mId);
+ break;
+ }
+
sp<Camera2Client> client = mClient.promote();
if (client == 0) {
res = discardNewCallback();