From 73718608715be53d3bb383ea3e4dd9553a6fdaf6 Mon Sep 17 00:00:00 2001 From: Luke Pulverenti Date: Wed, 19 Jun 2013 01:25:01 -0400 Subject: [PATCH] hls playlist fix --- MediaBrowser.Api/Playback/Hls/VideoHlsService.cs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/MediaBrowser.Api/Playback/Hls/VideoHlsService.cs b/MediaBrowser.Api/Playback/Hls/VideoHlsService.cs index 19c7d6e05..df74d3688 100644 --- a/MediaBrowser.Api/Playback/Hls/VideoHlsService.cs +++ b/MediaBrowser.Api/Playback/Hls/VideoHlsService.cs @@ -1,4 +1,5 @@ using System.IO; +using System.Linq; using MediaBrowser.Common.IO; using MediaBrowser.Common.MediaInfo; using MediaBrowser.Controller; @@ -63,6 +64,11 @@ namespace MediaBrowser.Api.Playback.Hls /// System.Object. public object Get(GetHlsVideoSegment request) { + foreach (var playlist in Directory.EnumerateFiles(ApplicationPaths.EncodedMediaCachePath, "*.m3u8").ToList()) + { + ApiEntryPoint.Instance.OnTranscodeBeginRequest(playlist, TranscodingJobType.Hls); + } + var file = SegmentFilePrefix + request.SegmentId + Path.GetExtension(RequestContext.PathInfo); file = Path.Combine(ApplicationPaths.EncodedMediaCachePath, file);