Fix homekit source panic on stop producer #734
This commit is contained in:
+2
-1
@@ -57,7 +57,8 @@ func (s *Server) DelSession(session *Session) {
|
||||
|
||||
delete(s.sessions, session.Remote.SSRC)
|
||||
|
||||
if len(s.sessions) == 0 {
|
||||
// check s.conn for https://github.com/AlexxIT/go2rtc/issues/734
|
||||
if len(s.sessions) == 0 && s.conn != nil {
|
||||
_ = s.conn.Close()
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user