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

Skip to content
Commit 9733b38a authored by Michael Hoisie's avatar Michael Hoisie
Browse files

Fix a thread leak due to a race condition in BackdropFrameRenderer

There was a subtle race condition in BackdropFrameRenderer where if it
is instantiated and immediately released with 'releaseRenderer', the
Looper is not quit, resulting in a thread leak. Add a check for this
scenario and avoid starting the Looper if this is detected.

This was caught in a Robolectric environment immediately after a recent
Android T jar update. It was exposed because some ViewRootImpl resize
logic was changed that resulted in BackdropFrameRenderer to be created
in Robolectric environments.

Test: all thread leaks stopped after fix was applied
Bug: 229816074
Change-Id: I525c363f827a230f3d23ee485a38d5b8a95c5beb
parent 4a0d85e1
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