From b25d8b506b7d5578bf05706b3875df218400606c Mon Sep 17 00:00:00 2001 From: Luke Pulverenti Date: Sat, 3 May 2014 16:43:09 -0400 Subject: [PATCH 1/2] update FlagsTostring --- MediaBrowser.Model/Dlna/ContentFeatureBuilder.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/MediaBrowser.Model/Dlna/ContentFeatureBuilder.cs b/MediaBrowser.Model/Dlna/ContentFeatureBuilder.cs index f3357dc5ba..7e21e1ef2f 100644 --- a/MediaBrowser.Model/Dlna/ContentFeatureBuilder.cs +++ b/MediaBrowser.Model/Dlna/ContentFeatureBuilder.cs @@ -138,8 +138,8 @@ namespace MediaBrowser.Model.Dlna //flagValue = flagValue | DlnaFlags.DLNA_ORG_FLAG_TIME_BASED_SEEK; } - var dlnaflags = string.Format(";DLNA.ORG_FLAGS={0}000000000000000000000000", - Enum.Format(typeof(DlnaFlags), flagValue, "x")); + var dlnaflags = string.Format(";DLNA.ORG_FLAGS={0}", + FlagsToString(flagValue)); var mediaProfile = _profile.GetVideoMediaProfile(container, audioCodec, From 310c217139bfd6a4192ac52d2816b06d0d839a24 Mon Sep 17 00:00:00 2001 From: Luke Pulverenti Date: Sat, 3 May 2014 16:43:22 -0400 Subject: [PATCH 2/2] Restore dlna headers --- MediaBrowser.Api/Playback/BaseStreamingService.cs | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/MediaBrowser.Api/Playback/BaseStreamingService.cs b/MediaBrowser.Api/Playback/BaseStreamingService.cs index ac06416557..69a812cbf4 100644 --- a/MediaBrowser.Api/Playback/BaseStreamingService.cs +++ b/MediaBrowser.Api/Playback/BaseStreamingService.cs @@ -1725,16 +1725,11 @@ namespace MediaBrowser.Api.Playback { var profile = state.DeviceProfile; - if (profile == null) - { - return; - } - var transferMode = GetHeader("transferMode.dlna.org"); responseHeaders["transferMode.dlna.org"] = string.IsNullOrEmpty(transferMode) ? "Streaming" : transferMode; responseHeaders["realTimeInfo.dlna.org"] = "DLNA.ORG_TLAG=*"; - if (state.RunTimeTicks.HasValue && !isStaticallyStreamed) + if (state.RunTimeTicks.HasValue && !isStaticallyStreamed && profile != null) { AddTimeSeekResponseHeaders(state, responseHeaders); }