mirror of
https://github.com/jellyfin/jellyfin.git
synced 2025-12-21 08:15:28 +03:00
update xml parsing
This commit is contained in:
@@ -218,6 +218,11 @@ namespace MediaBrowser.MediaEncoding.Probing
|
||||
switch (reader.Name)
|
||||
{
|
||||
case "dict":
|
||||
if (reader.IsEmptyElement)
|
||||
{
|
||||
reader.Read();
|
||||
continue;
|
||||
}
|
||||
using (var subtree = reader.ReadSubtree())
|
||||
{
|
||||
ReadFromDictNode(subtree, info);
|
||||
@@ -279,9 +284,14 @@ namespace MediaBrowser.MediaEncoding.Probing
|
||||
}
|
||||
break;
|
||||
case "array":
|
||||
if (!string.IsNullOrWhiteSpace(currentKey))
|
||||
if (reader.IsEmptyElement)
|
||||
{
|
||||
using (var subtree = reader.ReadSubtree())
|
||||
reader.Read();
|
||||
continue;
|
||||
}
|
||||
using (var subtree = reader.ReadSubtree())
|
||||
{
|
||||
if (!string.IsNullOrWhiteSpace(currentKey))
|
||||
{
|
||||
pairs.AddRange(ReadValueArray(subtree));
|
||||
}
|
||||
@@ -315,6 +325,12 @@ namespace MediaBrowser.MediaEncoding.Probing
|
||||
switch (reader.Name)
|
||||
{
|
||||
case "dict":
|
||||
|
||||
if (reader.IsEmptyElement)
|
||||
{
|
||||
reader.Read();
|
||||
continue;
|
||||
}
|
||||
using (var subtree = reader.ReadSubtree())
|
||||
{
|
||||
var dict = GetNameValuePair(subtree);
|
||||
|
||||
Reference in New Issue
Block a user