mirror of
https://github.com/pion/webrtc.git
synced 2025-12-24 11:51:03 +08:00
Add SetSCTPRTOMax to SettingEngine
Allows the user to cap the retranmission timeout, this change adds RTOMax to SettingEngine and pass it on when creating the SCTP Assocation
This commit is contained in:
@@ -269,3 +269,12 @@ func TestSetSCTPMaxReceiverBufferSize(t *testing.T) {
|
||||
s.SetSCTPMaxReceiveBufferSize(expSize)
|
||||
assert.Equal(t, expSize, s.sctp.maxReceiveBufferSize)
|
||||
}
|
||||
|
||||
func TestSetSCTPRTOMax(t *testing.T) {
|
||||
s := SettingEngine{}
|
||||
assert.Equal(t, time.Duration(0), s.sctp.rtoMax)
|
||||
|
||||
expSize := time.Second
|
||||
s.SetSCTPRTOMax(expSize)
|
||||
assert.Equal(t, expSize, s.sctp.rtoMax)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user