diff options
| author | 2021-05-10 12:56:18 -0700 | |
|---|---|---|
| committer | 2021-05-11 11:21:50 -0700 | |
| commit | 73fa26655809abf0c72ce7c4c239784ef3e14191 (patch) | |
| tree | 88fcab24f5882fc5113be2427daf8358f108ca8a /libs/gui/DisplayLuts.cpp | |
| parent | 75a9dc09754ce2a49c8aead9069bfa4fa69debb0 (diff) | |
Fix crash in Flattener dumpsys
When there are multiple connected displays where only one of them is
powered on, then caching is enabled on all displays but may
historically only been used on one. This means that mInitialLayerCounts
may be empty, which breaks retrieving the max element with
std::max_element. Add an emptiness check to sidestep that issue.
Bug: 187736454
Test: dumpsys SurfaceFlinger --planner
Change-Id: Iee917bb75c89e47f92f3440dd58bc58755e1f7b4
Diffstat (limited to 'libs/gui/DisplayLuts.cpp')
0 files changed, 0 insertions, 0 deletions