Skip to content

Commit

Permalink
voice: Fix race condition, see #237
Browse files Browse the repository at this point in the history
  • Loading branch information
diamondburned committed Jun 30, 2021
1 parent 26c0680 commit 30b69ea
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion voice/session.go
Original file line number Diff line number Diff line change
Expand Up @@ -374,5 +374,5 @@ func (s *Session) ensureClosed() {
// thread safe, and must be used very carefully. The backing buffer is always
// reused.
func (s *Session) ReadPacket() (*udp.Packet, error) {
return s.voiceUDP.ReadPacket()
return s.VoiceUDPConn().ReadPacket()
}

0 comments on commit 30b69ea

Please sign in to comment.