[fix] rtsp: 播放不存在的rtsp流,超时没有彻底释放

pull/286/head
q191201771 2 years ago
parent 5983992642
commit bea4701c23

@ -119,8 +119,8 @@ type Group struct {
rtmpSubSessionSet map[*rtmp.ServerSession]struct{}
httpflvSubSessionSet map[*httpflv.SubSession]struct{}
httptsSubSessionSet map[*httpts.SubSession]struct{}
rtspSubSessionSet map[*rtsp.SubSession]struct{}
waitRtspSubSessionSet map[*rtsp.SubSession]struct{}
rtspSubSessionSet map[*rtsp.SubSession]struct{} // 注意,使用这个容器时,一定要注意是否需要使用 waitRtspSubSessionSet
waitRtspSubSessionSet map[*rtsp.SubSession]struct{} // 注意,见 rtspSubSessionSet
hlsSubSessionSet map[*hls.SubSession]struct{}
// push
pushEnable bool

@ -150,6 +150,7 @@ func (group *Group) delHttptsSubSession(session *httpts.SubSession) {
func (group *Group) delRtspSubSession(session *rtsp.SubSession) {
Log.Debugf("[%s] [%s] del rtsp SubSession from group.", group.UniqueKey, session.UniqueKey())
delete(group.waitRtspSubSessionSet, session)
delete(group.rtspSubSessionSet, session)
}

Loading…
Cancel
Save