vlc/vlc-3.0 | branch: master | Pierre Ynard <[email protected]> | Mon Sep  7 
20:07:02 2020 +0200| [66c84ec7b825e67c821e437faf74a5d0a63aef11] | committer: 
Pierre Ynard

youtube.lua: fix parsing of empty description field

(cherry picked from commit 9ddd1b30f16431ce1f8f73eeec018d25a0221050)
Signed-off-by: Pierre Ynard <[email protected]>

> http://git.videolan.org/gitweb.cgi/vlc/vlc-3.0.git/?a=commit;h=66c84ec7b825e67c821e437faf74a5d0a63aef11
---

 share/lua/playlist/youtube.lua | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/share/lua/playlist/youtube.lua b/share/lua/playlist/youtube.lua
index e698974513..7b282bd6f1 100644
--- a/share/lua/playlist/youtube.lua
+++ b/share/lua/playlist/youtube.lua
@@ -333,6 +333,9 @@ function parse()
                 -- unlikely to access it due to #24957
                 description = string.match( line, 
'\\"shortDescription\\":\\"(.-[^\\])\\"')
                 if description then
+                    if string.match( description, '^\\"' ) then
+                        description = ""
+                    end
                     -- FIXME: do this properly (see #24958)
                     -- This way of unescaping is technically wrong
                     -- so as little as possible of it should be done

_______________________________________________
vlc-commits mailing list
[email protected]
https://mailman.videolan.org/listinfo/vlc-commits

Reply via email to