Browse Source

fix reading mpegts-muxed streams with ffmpeg (#222)

pull/235/head
aler9 5 years ago
parent
commit
355c400cc8
  1. 4
      internal/clientrtsp/client.go

4
internal/clientrtsp/client.go

@ -297,6 +297,10 @@ func (c *Client) run() {
reqPath, _ := base.PathSplitQuery(pathAndQuery) reqPath, _ := base.PathSplitQuery(pathAndQuery)
// path can end with a slash, remove it
// this is needed to support reading mpegts with ffmpeg
reqPath = strings.TrimSuffix(reqPath, "/")
if c.path != nil && reqPath != c.path.Name() { if c.path != nil && reqPath != c.path.Name() {
return &base.Response{ return &base.Response{
StatusCode: base.StatusBadRequest, StatusCode: base.StatusBadRequest,

Loading…
Cancel
Save