mirror of
https://github.com/bluenviron/mediamtx.git
synced 2025-12-29 22:42:00 -08:00
HLS: add Content-Type header (#408)
This commit is contained in:
parent
fc7041b551
commit
76f7b7a30a
1 changed files with 2 additions and 0 deletions
|
|
@ -629,6 +629,7 @@ func (c *Converter) runRequestHandler(terminate chan struct{}, done chan struct{
|
|||
cnt += f.Name() + ".ts\n"
|
||||
}
|
||||
|
||||
req.W.Header().Set("Content-Type", `application/x-mpegURL`)
|
||||
req.Res <- bytes.NewReader([]byte(cnt))
|
||||
}()
|
||||
|
||||
|
|
@ -645,6 +646,7 @@ func (c *Converter) runRequestHandler(terminate chan struct{}, done chan struct{
|
|||
continue
|
||||
}
|
||||
|
||||
req.W.Header().Set("Content-Type", `video/MP2T`)
|
||||
req.Res <- f.buf.NewReader()
|
||||
|
||||
case req.FileName == "":
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue