diff options
| author | Luke Pulverenti <luke.pulverenti@gmail.com> | 2013-03-27 10:54:00 -0400 |
|---|---|---|
| committer | Luke Pulverenti <luke.pulverenti@gmail.com> | 2013-03-27 10:54:00 -0400 |
| commit | e5faa92a18a001fd05ab48f330d004f77fee7230 (patch) | |
| tree | 4e4243b15c5328de696481f053fb4bf784ceb2c2 | |
| parent | 6de9c31c54be74e2668f5216f7b4832e63819ec2 (diff) | |
fix hls allow cache name
| -rw-r--r-- | MediaBrowser.Api/Playback/Hls/BaseHlsService.cs | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/MediaBrowser.Api/Playback/Hls/BaseHlsService.cs b/MediaBrowser.Api/Playback/Hls/BaseHlsService.cs index 015db04fb..697f0feb4 100644 --- a/MediaBrowser.Api/Playback/Hls/BaseHlsService.cs +++ b/MediaBrowser.Api/Playback/Hls/BaseHlsService.cs @@ -132,9 +132,13 @@ namespace MediaBrowser.Api.Playback.Hls // It's considered live while still encoding (EVENT). Once the encoding has finished, it's video on demand (VOD). var playlistType = fileText.IndexOf("#EXT-X-ENDLIST", StringComparison.OrdinalIgnoreCase) == -1 ? "EVENT" : "VOD"; + // fix this to make the media stream validator happy + // https://ffmpeg.org/trac/ffmpeg/ticket/2228 + fileText = fileText.Replace("#EXT-X-ALLOWCACHE", "#EXT-X-ALLOW-CACHE"); + // Add event type at the top fileText = fileText.Replace("#EXT-X-ALLOW-CACHE", "#EXT-X-PLAYLIST-TYPE:" + playlistType + Environment.NewLine + "#EXT-X-ALLOWCACHE"); - + return fileText; } |
