aboutsummaryrefslogtreecommitdiff
path: root/RSSDP/SsdpDevice.cs
diff options
context:
space:
mode:
authorLuke <luke.pulverenti@gmail.com>2017-11-27 15:18:00 -0500
committerGitHub <noreply@github.com>2017-11-27 15:18:00 -0500
commit9e452423e5f3a3811338bdad60c406baf8f3de26 (patch)
treed3075523535d00c4e4fb579dbf8863d742a21a40 /RSSDP/SsdpDevice.cs
parentacc17634a4cf5b8bff4fec6e7334f814fad78eb0 (diff)
parent26edcfefbb031a98f2d6f64b692bba07587614b7 (diff)
Merge pull request #3045 from MediaBrowser/dev
Dev
Diffstat (limited to 'RSSDP/SsdpDevice.cs')
-rw-r--r--RSSDP/SsdpDevice.cs8
1 files changed, 8 insertions, 0 deletions
diff --git a/RSSDP/SsdpDevice.cs b/RSSDP/SsdpDevice.cs
index cda11f0a4..65d9be139 100644
--- a/RSSDP/SsdpDevice.cs
+++ b/RSSDP/SsdpDevice.cs
@@ -743,6 +743,14 @@ namespace Rssdp
private static void AddCustomProperty(XmlReader reader, SsdpDevice device)
{
+ // If the property is an empty element, there is no value to read
+ // Advance the reader and return
+ if (reader.IsEmptyElement)
+ {
+ reader.Read();
+ return;
+ }
+
var newProp = new SsdpDeviceProperty() { Namespace = reader.Prefix, Name = reader.LocalName };
int depth = reader.Depth;
reader.Read();