diff --git a/core/rtmp/rtmp.go b/core/rtmp/rtmp.go index 90cbdf702..7173f0da8 100644 --- a/core/rtmp/rtmp.go +++ b/core/rtmp/rtmp.go @@ -123,6 +123,10 @@ func HandleConn(c *rtmp.Conn, nc net.Conn) { } func handleDisconnect(conn net.Conn) { + if !_hasInboundRTMPConnection { + return + } + log.Infoln("RTMP disconnected.") conn.Close() _pipe.Close()