aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Model/Dlna/ConditionProcessor.cs
diff options
context:
space:
mode:
Diffstat (limited to 'MediaBrowser.Model/Dlna/ConditionProcessor.cs')
-rw-r--r--MediaBrowser.Model/Dlna/ConditionProcessor.cs10
1 files changed, 8 insertions, 2 deletions
diff --git a/MediaBrowser.Model/Dlna/ConditionProcessor.cs b/MediaBrowser.Model/Dlna/ConditionProcessor.cs
index 2e337982f..3577c6f01 100644
--- a/MediaBrowser.Model/Dlna/ConditionProcessor.cs
+++ b/MediaBrowser.Model/Dlna/ConditionProcessor.cs
@@ -18,7 +18,7 @@ namespace MediaBrowser.Model.Dlna
double? videoLevel,
double? videoFramerate,
int? packetLength,
- TransportStreamTimestamp timestamp)
+ TransportStreamTimestamp? timestamp)
{
switch (condition.Property)
{
@@ -176,8 +176,14 @@ namespace MediaBrowser.Model.Dlna
return false;
}
- private bool IsConditionSatisfied(ProfileCondition condition, TransportStreamTimestamp timestamp)
+ private bool IsConditionSatisfied(ProfileCondition condition, TransportStreamTimestamp? timestamp)
{
+ if (!timestamp.HasValue)
+ {
+ // If the value is unknown, it satisfies if not marked as required
+ return !condition.IsRequired;
+ }
+
var expected = (TransportStreamTimestamp)Enum.Parse(typeof(TransportStreamTimestamp), condition.Value, true);
switch (condition.Condition)