Skip to content

Commit

Permalink
Fix race when closing ICE Transport
Browse files Browse the repository at this point in the history
Struct member is copied to stack already, `stop` just incorrectly was
referencing the member.

Found in CI
  • Loading branch information
Sean-Der committed Oct 28, 2024
1 parent ae89317 commit 85bd5d2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion icetransport.go
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ func (t *ICETransport) stop(shouldGracefullyClose bool) error {
gatherer := t.gatherer
t.lock.Unlock()

if t.mux != nil {
if mux != nil {
var closeErrs []error
if shouldGracefullyClose && gatherer != nil {
// we can't access icegatherer/icetransport.Close via
Expand Down

0 comments on commit 85bd5d2

Please sign in to comment.