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

Commit 17991ab9 authored by Treehugger Robot's avatar Treehugger Robot Committed by Automerger Merge Worker
Browse files

Merge "Close unused Image before acquire new one" into main am: 9001ecb1

parents c214ec44 9001ecb1
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -365,6 +365,9 @@ public class ScrollCaptureClient {
        @Override
        public void onImageAvailable(ImageReader reader) {
            synchronized (mLock) {
                if (mCapturedImage != null) {
                    mCapturedImage.close();
                }
                mCapturedImage = mReader.acquireLatestImage();
                if (mCapturedArea != null) {
                    completeCaptureRequest();