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

Commit 82d291ec authored by Android Build Merger (Role)'s avatar Android Build Merger (Role) Committed by Android (Google) Code Review
Browse files

Merge "Merge "Check if mSurface is valid before create SurfaceSession" am:...

Merge "Merge "Check if mSurface is valid before create SurfaceSession" am: fe118cfd am: 07eeea78" into pi-dev-plus-aosp
parents d37b8ac8 4c767a17
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -302,6 +302,9 @@ class TaskSnapshotSurface implements StartingSurface {
    }

    private void drawSizeMismatchSnapshot(GraphicBuffer buffer) {
        if (!mSurface.isValid()) {
            throw new IllegalStateException("mSurface does not hold a valid surface.");
        }
        final SurfaceSession session = new SurfaceSession(mSurface);

        // Keep a reference to it such that it doesn't get destroyed when finalized.