RESTRICT AUTOMERGE SurfaceFlinger: fix a potential race condition in stealReceiveChannel

Add a mutex to prevent a potential race condition.

Bug: 232541124
Test: See bug for details
Change-Id: Ia338f124c786bf12d6adba10a67b9048fe9c34a5
(cherry picked from commit 29e34cfcf95c6de1f2cbfe2bf588e4e354dbabe0)
Merged-In: Ia338f124c786bf12d6adba10a67b9048fe9c34a5
2 files changed