rtsp: normalize debug logging of requests / responses (#2321)

This commit is contained in:
Alessandro Ros 2023-09-09 23:08:47 +02:00 committed by GitHub
parent 6402e18b5c
commit 4b5a977c86
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -104,10 +104,10 @@ func (s *rtspSource) run(ctx context.Context, cnf *conf.PathConf, reloadConf cha
WriteQueueSize: s.writeQueueSize,
AnyPortEnable: cnf.SourceAnyPortEnable,
OnRequest: func(req *base.Request) {
s.Log(logger.Debug, "c->s %v", req)
s.Log(logger.Debug, "[c->s] %v", req)
},
OnResponse: func(res *base.Response) {
s.Log(logger.Debug, "s->c %v", res)
s.Log(logger.Debug, "[s->c] %v", res)
},
OnTransportSwitch: func(err error) {
s.Log(logger.Warn, err.Error())