Do not restart receiver on codec change mid-session. (#4225)

* Do not restart receiver on codec change mid-session.

This is not supported and was an erroneous change during the
receiver_base/buffer_base + RTP stream restart consolidation. Also make
the codec munger creation more resilient.

* fix test
This commit is contained in:
Raja Subramanian
2026-01-08 02:35:32 +05:30
committed by GitHub
parent dafdc36e3e
commit 7fae5ac9e6
4 changed files with 17 additions and 12 deletions
-2
View File
@@ -964,8 +964,6 @@ func (b *BufferBase) handleCodecChange(newPT uint8) {
b.rtxPayloadType = rtxPt
b.mime = mime.NormalizeMimeType(newCodec.MimeType)
b.restartStreamLocked("codec-change", true)
if f := b.onCodecChange; f != nil {
go f(newCodec)
}