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

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

Merge "Camera: Avoid flushing uninitialized devices"

parents 5ceb8c8c ed2ebe4b
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -2014,6 +2014,13 @@ status_t Camera3Device::flush(int64_t *frameNumber) {

    {
        Mutex::Autolock l(mLock);

        // b/116514106 "disconnect()" can get called twice for the same device. The
        // camera device will not be initialized during the second run.
        if (mStatus == STATUS_UNINITIALIZED) {
            return OK;
        }

        mRequestThread->clear(/*out*/frameNumber);
    }