summaryrefslogtreecommitdiff
path: root/libs/gui/SurfaceControl.cpp
diff options
context:
space:
mode:
author Jorim Jaggi <jjaggi@google.com> 2021-06-16 17:49:08 +0200
committer Jorim Jaggi <jjaggi@google.com> 2021-06-16 17:50:32 +0200
commit6ed2ea83246b95a47808570e96e6f0e027092629 (patch)
tree56240486432a6a2cb08e1d3d686a080a37107905 /libs/gui/SurfaceControl.cpp
parent1283885c6478edabb3bcdf26a971818a9f510d40 (diff)
Ensure reportFrameMetrics not being called on deleted instance
Since onSurfaceStatsAvailable gets called on binder-thread, we need to ensure that instance doesn't get released while onSurfaceStatsAvailable is calling reportFrameMetrics. We do this by introducing a lock for register/unregister/callback, such than when unregister completes, there won't be any "hanging" callback anymore such that the callback can't be called anymore on deleted instances. Test: Boots Bug: 188934435 Change-Id: Ifc5357bd181e0cd065cdecd0188836a35f87b3e2
Diffstat (limited to 'libs/gui/SurfaceControl.cpp')
0 files changed, 0 insertions, 0 deletions