mirror of
https://github.com/livekit/livekit.git
synced 2026-05-17 00:36:15 +00:00
f29a28611b
It is possible that onBindAndConnectedChanged gets executed in such a way that `writable` does not have the correct value in some very rare timing case (i. e. case like two executions of the function is racing and one atomic was read on first exeuction and second execution runs and sets `writable` and then first execution completes the sets `writable` to incorrect value based on stale read of first execution). Prevent it by executing under bind lock.