修复hook重复通知publish done事件

This commit is contained in:
yangjiechina
2024-07-14 17:59:56 +08:00
parent f1c6b3cada
commit db435f17aa
4 changed files with 17 additions and 9 deletions

View File

@@ -190,7 +190,7 @@ func (s *BaseSink) DesiredVideoCodecId() utils.AVCodecID {
// 拉流断开连接,不需要考虑线程安全
// 踢流走source管道删除,并且关闭Conn
func (s *BaseSink) Close() {
if SessionStateClosed != s.State_ {
if SessionStateClosed == s.State_ {
return
}