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

Commit 5ad0be28 authored by Treehugger Robot's avatar Treehugger Robot Committed by Automerger Merge Worker
Browse files

Merge "CameraSource: Remove CHECK if set preview target fails with CameraSource" am: 0cc62bf0

parents d5879e86 0cc62bf0
Loading
Loading
Loading
Loading
+5 −3
Original line number Diff line number Diff line
@@ -564,9 +564,11 @@ status_t CameraSource::initWithCameraAccess(
    // Set the preview display. Skip this if mSurface is null because
    // applications may already set a surface to the camera.
    if (mSurface != NULL) {
        // This CHECK is good, since we just passed the lock/unlock
        // check earlier by calling mCamera->setParameters().
        CHECK_EQ((status_t)OK, mCamera->setPreviewTarget(mSurface));
        // Surface may be set incorrectly or could already be used even if we just
        // passed the lock/unlock check earlier by calling mCamera->setParameters().
        if ((err = mCamera->setPreviewTarget(mSurface)) != OK) {
            return err;
        }
    }

    // Use buffer queue to receive video buffers from camera