Skip to content

Commit

Permalink
Don't go from Idle(UAC) straight to the Dead state. The problem with
Browse files Browse the repository at this point in the history
that, is Dead's OnActivate() cleans up all callback pointers, thus
making a subsequent self.ua.DiscCb() effectively a NOP.

When external media relay is active, we can be staying in the
Idle(UAC) state for an extended amount of time, waiting for the
remote rtpproxy to complete a request.
  • Loading branch information
sobomax committed Oct 26, 2024
1 parent 70741e4 commit 25d0976
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sippy/uac_state_idle.go
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ func (self *UacStateIdle) RecvEvent(_event sippy_types.CCEvent) (sippy_types.UaS
disconnect_ts, _ := sippy_time.NewMonoTime()
self.ua.SetDisconnectTs(disconnect_ts)
}
return NewUaStateDead(self.ua, self.config), func() { self.ua.DiscCb(_event.GetRtime(), _event.GetOrigin(), 0, nil) }, nil
return NewUaStateDisconnected(self.ua, self.config), func() { self.ua.DiscCb(_event.GetRtime(), _event.GetOrigin(), 0, nil) }, nil
}

func (self *UacStateIdle) ID() sippy_types.UaStateID {
Expand Down

0 comments on commit 25d0976

Please sign in to comment.