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

Commit c4491b4c authored by Chris Li's avatar Chris Li
Browse files

Ensure lock for unregisterActivityConfigurationListener

onServiceStarted is called from AM without WM lock.

Fix: 364692215
Test: build
Flag: EXEMPT bug fix
Change-Id: I368620c7e8b19f1e8b0a51f8f20190cfb534d105
parent 5b8b3ed4
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -1926,7 +1926,12 @@ public class WindowProcessController extends ConfigurationContainer<Configuratio
                // showing.
                // If the configuration has been overridden by previous activity, empty it.
                mIsActivityConfigOverrideAllowed = false;
                // The call to `onServiceStarted` is not guarded with WM lock.
                mAtm.mH.post(() -> {
                    synchronized (mAtm.mGlobalLock) {
                        unregisterActivityConfigurationListener();
                    }
                });
                break;
            default:
                break;