diff options
author | ChrisK2 <spam@kalania.de> | 2015-05-07 20:41:46 +0200 |
---|---|---|
committer | ChrisK2 <spam@kalania.de> | 2015-05-07 20:41:46 +0200 |
commit | 6a0a67034d925a640a9239754c5f06e6e689c27d (patch) | |
tree | bc7d4b86b402837c3263db7f3ef820a8091d15a2 /player/lua | |
parent | cd5ab98ff992217abfd0234601c21eb0fe0dbc19 (diff) |
ytdl_hook: Escape EDL URLs
Should prevent the EDL parser from tripping over = and , in the
URL.
Diffstat (limited to 'player/lua')
-rw-r--r-- | player/lua/ytdl_hook.lua | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/player/lua/ytdl_hook.lua b/player/lua/ytdl_hook.lua index d6fa1ca7c2..a3be2be812 100644 --- a/player/lua/ytdl_hook.lua +++ b/player/lua/ytdl_hook.lua @@ -162,7 +162,9 @@ mp.add_hook("on_load", 10, function () local playlist = "edl://" for i, entry in pairs(json.entries) do - playlist = playlist .. entry.url .. ";" + local urllength = string.len(entry.url) + playlist = playlist .. "%" .. urllength .. "%" .. entry.url .. ";" + end msg.debug("EDL: " .. playlist) |