diff options
author | 2021-06-09 12:32:39 -0700 | |
---|---|---|
committer | 2021-06-10 08:41:17 -0700 | |
commit | 119a7f55911ba3e96a35300090bf83d00c5dc4a4 (patch) | |
tree | dd328ef5c839781e1d1f254cc62814348bcf67b2 | |
parent | 72cd5f15528e6b930fadfdef1d79722ea7ff02e7 (diff) |
Fix RRO handleConfigurationChanged race condition
Retrieval of the system and system UI themes should be done with the
ResourcesManager lock held to ensure the theme retrieved has the new
overlays applied.
Bug: 189100984
Test: manual
Change-Id: Ibe27ec745ea5a914d3d05e393598a336d96a55e6
-rw-r--r-- | core/java/android/app/ConfigurationController.java | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/core/java/android/app/ConfigurationController.java b/core/java/android/app/ConfigurationController.java index 6d92201db8ec..f79e0780ecae 100644 --- a/core/java/android/app/ConfigurationController.java +++ b/core/java/android/app/ConfigurationController.java @@ -158,10 +158,9 @@ class ConfigurationController { int configDiff; boolean equivalent; - final Resources.Theme systemTheme = mActivityThread.getSystemContext().getTheme(); - final Resources.Theme systemUiTheme = mActivityThread.getSystemUiContext().getTheme(); - synchronized (mResourcesManager) { + final Resources.Theme systemTheme = mActivityThread.getSystemContext().getTheme(); + final Resources.Theme systemUiTheme = mActivityThread.getSystemUiContext().getTheme(); if (mPendingConfiguration != null) { if (!mPendingConfiguration.isOtherSeqNewer(config)) { config = mPendingConfiguration; |