aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuke Pulverenti <luke.pulverenti@gmail.com>2017-03-25 18:08:20 -0400
committerLuke Pulverenti <luke.pulverenti@gmail.com>2017-03-25 18:08:20 -0400
commit0cffe00aae80342d050a40848050f7cae3af8f61 (patch)
tree56726ce67c91f435f5a8d24f019d6f1a5d1e5413
parentaa8f3cd493509ce4d6af836d3f231e7437a8ae49 (diff)
handle -1 content length
-rw-r--r--MediaBrowser.Api/Playback/Progressive/BaseProgressiveStreamingService.cs3
1 files changed, 2 insertions, 1 deletions
diff --git a/MediaBrowser.Api/Playback/Progressive/BaseProgressiveStreamingService.cs b/MediaBrowser.Api/Playback/Progressive/BaseProgressiveStreamingService.cs
index 441fff849..646a91c27 100644
--- a/MediaBrowser.Api/Playback/Progressive/BaseProgressiveStreamingService.cs
+++ b/MediaBrowser.Api/Playback/Progressive/BaseProgressiveStreamingService.cs
@@ -295,7 +295,8 @@ namespace MediaBrowser.Api.Playback.Progressive
responseHeaders["Accept-Ranges"] = "none";
}
- if (response.ContentLength.HasValue)
+ // Seeing cases of -1 here
+ if (response.ContentLength.HasValue && response.ContentLength.Value >= 0)
{
responseHeaders["Content-Length"] = response.ContentLength.Value.ToString(UsCulture);
}