[vlc-commits] commit: appletrailers: fix location finding (Ilkka Ollakka )
git at videolan.org
git at videolan.org
Sun Jun 6 11:20:48 CEST 2010
vlc | branch: master | Ilkka Ollakka <ileoo at videolan.org> | Sun Jun 6 12:20:01 2010 +0300| [c3d96600618add7768f713ccf1fcdddaf06dd1fb] | committer: Ilkka Ollakka
appletrailers: fix location finding
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=c3d96600618add7768f713ccf1fcdddaf06dd1fb
---
share/lua/sd/appletrailers.lua | 7 +++++--
1 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/share/lua/sd/appletrailers.lua b/share/lua/sd/appletrailers.lua
index 93d3eff..3675c5d 100644
--- a/share/lua/sd/appletrailers.lua
+++ b/share/lua/sd/appletrailers.lua
@@ -39,9 +39,12 @@ function main()
if string.match( line, "title" ) then
title = vlc.strings.resolve_xml_special_chars( find( line, "title\":\"(.-)\""))
art = find( line, "poster\":\"(.-)\"")
- art = "http://trailers.apple.com"..art
+ if string.match( art, "http://" ) then
+ else
+ art = "http://trailers.apple.com"..art
+ end
- url = find( line, "url\":\"(.-)\"")
+ url = find( line, "location\":\"(.-)\"")
playlist = vlc.stream( "http://trailers.apple.com"..url.."includes/playlists/web.inc" )
if not playlist then
vlc.msg.info("Didn't get playlist...")
More information about the vlc-commits
mailing list