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

Skip to content
Commit 1e7589af authored by Joanne Chung's avatar Joanne Chung
Browse files

Fix deadlock between PackageManager and DisplayManager

UpdateOwnershipHelper#readUpdateOwnerDenyList calls getResources()
that will call getDisplayMetrics. In DisplayMetrics() that needs to
access a lock in DisplayManagerGlobal. When calling this method
inside mPm.mLock, it may trigger the deadlock between PackageManager
and DisplayManager.

To fix this issue, try to get the denylist in the handler thread and
outside the mPm.mLock.

Bug: 305615356
Test: manual. Add logs to make sure getResources() doesn't be called
inside mPm.mLock

Change-Id: I3dea7b1df6f115d7c1cffda6a9d51070a5d7dd80
parent 5ea095ca
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