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

Commit e456bdf2 authored by Michal Karpinski's avatar Michal Karpinski Committed by Android (Google) Code Review
Browse files

Merge "Create a new reference of r.curApp to post for the delayed job"

parents 65b245a1 8a63b09f
Loading
Loading
Loading
Loading
+2 −3
Original line number Diff line number Diff line
@@ -460,10 +460,9 @@ public final class BroadcastQueue {
                // that request - we don't want the token to be swept from under our feet...
                mHandler.removeCallbacksAndMessages(msgToken);
                // ...then schedule the removal of the token after the extended timeout
                final ProcessRecord app = r.curApp;
                mHandler.postAtTime(() -> {
                    if (r.curApp != null) {
                        r.curApp.removeAllowBackgroundActivityStartsToken(r);
                    }
                    app.removeAllowBackgroundActivityStartsToken(r);
                }, msgToken, (r.receiverTime + mConstants.ALLOW_BG_ACTIVITY_START_TIMEOUT));
            }
        }