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

Commit fefdd45a authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Automerger Merge Worker
Browse files

Merge "End the trace section in FrameTracker#cancel if it has begun" into sc-dev am: a6907d35

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13825989

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I3d2e02043f069e5649139fd42a4db0dbfc8ba50b
parents 50be3d64 a6907d35
Loading
Loading
Loading
Loading
+2 −3
Original line number Diff line number Diff line
@@ -206,9 +206,8 @@ public class FrameTracker extends SurfaceControl.OnJankDataListener
     * Cancel the trace session of the CUJ.
     */
    public synchronized void cancel() {
        // The session is ongoing, end the trace session.
        // That means the cancel call is from external invocation, not from end().
        if (mBeginVsyncId != INVALID_ID && mEndVsyncId == INVALID_ID) {
        // We don't need to end the trace section if it never begun.
        if (mBeginVsyncId != INVALID_ID) {
            Trace.endAsyncSection(mSession.getName(), (int) mBeginVsyncId);
        }
        mCancelled = true;