summaryrefslogtreecommitdiff
path: root/libs/androidfw/ApkParsing.cpp
diff options
context:
space:
mode:
author Yasin Kilicdere <tyk@google.com> 2023-01-04 14:17:40 +0000
committer Yasin Kilicdere <tyk@google.com> 2023-01-04 18:41:47 +0000
commit75266fb9d258bd859fb8f9fee89648284dc1bf9a (patch)
tree26e09b216fb3bcad59cc13011df23eec93b1ff60 /libs/androidfw/ApkParsing.cpp
parent03882bc8bd8d3f1b5e7d00b697b7ae4182f41e7e (diff)
Force stop a user before removing it in perf tests.
Removing users immediately after starting them was causing system crashes on other parts of the Android. In removeUsers() it was waited for ACTION_MEDIA_MOUNTED before removing started users. But it was deciding whether a user has been started by checking if ACTION_USER_STARTED broadcast was received for that user. Depending on a broadcast was wrong because it might not have been received in time. Changing that part with UM.isUserRunning API would fix the issue but this time since the user might be started and stopped multiple times during the tests, checking for ACTION_MEDIA_MOUNTED was making the code too complicated since it could be received multiple times. This CL simply force stops the user before removing it to solve the problem. Bug: 262407660 Bug: 236229621 Bug: 233240023 Test: atest UserLifecycleTests Change-Id: Ica715e88d88761d969d02c761ea845d5b82b17e9
Diffstat (limited to 'libs/androidfw/ApkParsing.cpp')
0 files changed, 0 insertions, 0 deletions