Skip to content
Commit 2f37c0d5 authored by Riddle Hsu's avatar Riddle Hsu
Browse files

Avoid misleading log while warm launch

When launch a new activity on an existing process, the original code
will let the activity with lastLaunchTime=0 go through setProc ->
addActivityIfNeeded -> setLastActivityLaunchTime. And because the
existing process has mLastActivityLaunchTime>0, the method will print
a confusing log.

So just move the assignment of lastLaunchTime before setProcess. And
remove the later setLastActivityLaunchTime because setProcess has
already called it.

Bug: 243164648
Test: Launch an activity and calls finish(), and then launch it again.
      There should not have a warning log:
      "Tried to set launchTime (0) < mLastActivityLaunchTime".
Change-Id: Id767a0589cbb7d9730a3deceb12789341391cdff
parent 0054cebd
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment