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

Commit de844434 authored by Robert Carr's avatar Robert Carr
Browse files

SurfaceView: Release Surface with SurfaceControl.

Not so drastic as we were releasing the Server side resources
anyway but the close guard is producing a strict mode warning.

Bug: 35955183
Test: cts-tradefed run cts -m CtsViewTestCases -t android.view.cts.SurfaceViewTest#surfaceInvalidatedWhileDetaching
Change-Id: Id250fff8d001d5d82458af1a732c0e123f925dad
parent 6b1989c7
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -678,6 +678,7 @@ public class SurfaceView extends View implements ViewRootImpl.WindowStoppedCallb
                    mIsCreating = false;
                    if (mSurfaceControl != null && !mSurfaceCreated) {
                        mSurfaceControl.destroy();
                        mSurface.release();
                        mSurfaceControl = null;
                    }
                }