1
0
Fork 0
forked from External/mediamtx

RTSP/RTMP source: fix error 'no one is publishing to path' that happens after some seconds, when sourceOnDemand is enabled (#334)

This commit is contained in:
aler9 2021-04-03 13:40:33 +02:00
parent 99a07c0d33
commit 377bb31c50

View file

@ -479,13 +479,13 @@ func (pa *Path) removeClient(c client.Client) {
}
func (pa *Path) onSourceSetReady() {
pa.sourceState = sourceStateReady
if pa.sourceState == sourceStateWaitingDescribe {
pa.describeTimer.Stop()
pa.describeTimer = newEmptyTimer()
}
pa.sourceState = sourceStateReady
for _, req := range pa.describeRequests {
req.Res <- client.DescribeRes{pa.sourceTracks.Write(), "", nil} //nolint:govet
}