Ensure older session does not clobeer newer session. (#1974)

This commit is contained in:
Raja Subramanian
2023-08-18 02:00:43 +05:30
committed by GitHub
parent 129b1df8e6
commit 1a32439d7e
2 changed files with 10 additions and 2 deletions
+1 -2
View File
@@ -58,8 +58,7 @@ func (p *ParticipantImpl) SendJoinResponse(joinResponse *livekit.JoinResponse) e
return err
}
// update state after to sending message, so that no participant updates could slip through before JoinResponse is
// sent
// update state after sending message, so that no participant updates could slip through before JoinResponse is sent
p.updateLock.Lock()
if p.State() == livekit.ParticipantInfo_JOINING {
p.updateState(livekit.ParticipantInfo_JOINED)