Cancel SRT/RTMP session immediately on disconnect

This commit is contained in:
Ingo Oppermann 2023-09-21 15:09:19 +02:00
parent 477243a38e
commit c7979efb07
No known key found for this signature in database
GPG Key ID: 2AB32426E9DD229E
2 changed files with 2 additions and 0 deletions

View File

@ -66,6 +66,7 @@ func (c *client) ticker(ctx context.Context) {
func (c *client) Close() {
c.cancel()
c.conn.Close()
c.collector.Close(c.id)
}
// channel represents a stream that is sent to the server

View File

@ -68,6 +68,7 @@ func (c *client) ticker(ctx context.Context) {
func (c *client) Close() {
c.cancel()
c.conn.Close()
c.collector.Close(c.id)
}
// channel represents a stream that is sent to the server