unbreak youtube with get_flash_videos; they now require a signature url param.

This commit is contained in:
sthen 2012-09-27 23:35:49 +00:00
parent 35cd2db00c
commit 11cee742a1
2 changed files with 30 additions and 1 deletions

View File

@ -1,9 +1,10 @@
# $OpenBSD: Makefile,v 1.19 2012/07/16 10:14:28 sthen Exp $ # $OpenBSD: Makefile,v 1.20 2012/09/27 23:35:49 sthen Exp $
COMMENT= download flash video files from various sites COMMENT= download flash video files from various sites
DISTNAME= monsieurvideo-get-flash-videos-v1.24_02-268-g162d964 DISTNAME= monsieurvideo-get-flash-videos-v1.24_02-268-g162d964
PKGNAME= get_flash_videos-1.24.20120716 PKGNAME= get_flash_videos-1.24.20120716
REVISION= 0
WRKDIST= ${WRKDIR}/monsieurvideo-get-flash-videos-162d964 WRKDIST= ${WRKDIR}/monsieurvideo-get-flash-videos-162d964
CATEGORIES= multimedia CATEGORIES= multimedia

View File

@ -0,0 +1,28 @@
$OpenBSD: patch-lib_FlashVideo_Site_Youtube_pm,v 1.7 2012/09/27 23:35:49 sthen Exp $
https://github.com/pder/get-flash-videos/commit/46f4dae05a1ad33dd0561c23d185fca1663bb4cf
--- lib/FlashVideo/Site/Youtube.pm.orig Fri Sep 28 00:30:06 2012
+++ lib/FlashVideo/Site/Youtube.pm Fri Sep 28 00:32:57 2012
@@ -178,6 +178,7 @@ sub parse_youtube_url_encoded_fmt_stream_map {
my $format = "";
my $url = "";
+ my $sig = "";
foreach my $pair (split /&/, $params) {
my ($name, $value) = split /=/, $pair;
@@ -185,10 +186,12 @@ sub parse_youtube_url_encoded_fmt_stream_map {
$format = $value;
} elsif ($name eq "url") {
$url = uri_unescape($value);
+ } elsif ($name eq "sig") {
+ $sig = $value;
}
}
- $map->{$format} = $url;
+ $map->{$format} = "$url&signature=$sig";
}
return $map;