server: add error to OnSessionClose()

This commit is contained in:
aler9
2021-05-04 15:51:35 +02:00
committed by Alessandro Ros
parent 6f749e6ba8
commit 9d42a63102
9 changed files with 99 additions and 79 deletions

View File

@@ -37,7 +37,7 @@ func (sh *serverHandler) OnSessionOpen(ss *gortsplib.ServerSession) {
}
// called when a session is closed.
func (sh *serverHandler) OnSessionClose(ss *gortsplib.ServerSession) {
func (sh *serverHandler) OnSessionClose(ss *gortsplib.ServerSession, err error) {
log.Printf("session closed")
sh.mutex.Lock()