commit | 5fa7ad6fa1316036819ec506205888eac5512f68 | [log] [tgz] |
---|---|---|
author | Mathias Agopian <mathias@google.com> | Tue May 03 16:21:41 2011 -0700 |
committer | Mathias Agopian <mathias@google.com> | Tue May 03 16:21:41 2011 -0700 |
tree | 9e2a6a9cb7c4dff7d9c28813cebee2f08435e396 | |
parent | 939ccad344c5f32bc9e7dbfa80648c1e75cac62a [diff] |
Fix a race-condtion in SurfaceFlinger that could lead to a crash. Client::mLayers could be accessed from different threads. On one side from Client::attachLayer() which is currently called from a binder thread; on the other side from Client::detachLayer() which is always called from the main thread. This could lead to a corruption of Client::mLayers. We fix this issue by adding an internal lock to Client. Change-Id: Ib1317d7750ed5030e6f577efe34b69fc10198bd3