HLS: add Access-Control-Allow-Origin to every HTTP response; add parameter hlsAllowOrigin (#415)

This commit is contained in:
aler9 2021-06-23 19:28:27 +02:00
parent 0d34a10c1c
commit 7b1466146b
5 changed files with 16 additions and 4 deletions

View file

@ -307,6 +307,7 @@ func (p *program) createResources(initial bool) error {
p.conf.HLSAddress,
p.conf.HLSSegmentCount,
p.conf.HLSSegmentDuration,
p.conf.HLSAllowOrigin,
p.conf.ReadBufferCount,
p.stats,
p.pathMan,
@ -426,6 +427,7 @@ func (p *program) closeResources(newConf *conf.Conf) {
newConf.HLSAddress != p.conf.HLSAddress ||
newConf.HLSSegmentCount != p.conf.HLSSegmentCount ||
newConf.HLSSegmentDuration != p.conf.HLSSegmentDuration ||
newConf.HLSAllowOrigin != p.conf.HLSAllowOrigin ||
newConf.ReadBufferCount != p.conf.ReadBufferCount ||
closeStats ||
closePathMan {