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

Commit 3761f333 authored by Jeff Sharkey's avatar Jeff Sharkey
Browse files

Move StrictMode timers to postAtFrontOfQueue().

StrictMode posts a message to estimate how long the main thread was
blocked during a violation.  Currently, any pending messages are
counted against the violation.  To avoid this, switch to using
postAtFrontOfQueue().

Bug: 6119289
Change-Id: I94530632ca678b78b75a698cf9193641b102be9a
parent f9f1d066
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1201,7 +1201,7 @@ public final class StrictMode {
            // throttled back to 60fps via SurfaceFlinger/View
            // invalidates, _not_ by posting frame updates every 16
            // milliseconds.
            threadHandler.get().post(new Runnable() {
            threadHandler.get().postAtFrontOfQueue(new Runnable() {
                    public void run() {
                        long loopFinishTime = SystemClock.uptimeMillis();