Skip to content

Commit

Permalink
Fix MPEG-DASH manifest parse failure in Kodi/ISA v20 anxdpanic#595
Browse files Browse the repository at this point in the history
  • Loading branch information
MoojMidge committed Feb 24, 2024
1 parent 48bf546 commit 1f9fac4
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion resources/lib/youtube_plugin/youtube/helper/video_info.py
Original file line number Diff line number Diff line change
Expand Up @@ -1869,6 +1869,12 @@ def _filter_group(previous_group, previous_stream, item):
else:
kind = lang_code

url = (unquote(subtitle['url'])
.replace("&", "&")
.replace('"', """)
.replace("<", "&lt;")
.replace(">", "&gt;"))

output.extend((
'\t\t<AdaptationSet'
' id="', str(set_id), '"'
Expand All @@ -1891,7 +1897,7 @@ def _filter_group(previous_group, previous_stream, item):
# unsure about what value to use for bandwidth
' bandwidth="268"'
'>\n'
'\t\t\t\t<BaseURL>', subtitle['url'], '</BaseURL>\n'
'\t\t\t\t<BaseURL>', url, '</BaseURL>\n'
'\t\t\t</Representation>\n'
'\t\t</AdaptationSet>\n'
))
Expand Down

0 comments on commit 1f9fac4

Please sign in to comment.