summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2009-10-28 22:56:32 +0000
committerKarl Berry <karl@freefriends.org>2009-10-28 22:56:32 +0000
commit7c9607ed7b752305f7757c2e18cfa4fa03834d27 (patch)
tree23d36afaffe192bafe6abb01dc80d62ddde939d5
parentff2e88969261951ddbee701457719ea5dea919d4 (diff)
(_download_file): set --user-agent=texlive,
requested by CTAN. git-svn-id: svn://tug.org/texlive/trunk@15902 c570f23f-e606-0410-a88d-b1316a301751
-rw-r--r--Master/tlpkg/TeXLive/TLUtils.pm7
1 files changed, 4 insertions, 3 deletions
diff --git a/Master/tlpkg/TeXLive/TLUtils.pm b/Master/tlpkg/TeXLive/TLUtils.pm
index 8341b8c605c..bb6aeca29e0 100644
--- a/Master/tlpkg/TeXLive/TLUtils.pm
+++ b/Master/tlpkg/TeXLive/TLUtils.pm
@@ -2179,7 +2179,7 @@ we try a literal C<wget>.
Downloading honors two environment variables: C<TL_DOWNLOAD_PROGRAM> and
C<TL_DOWNLOAD_ARGS>. The former overrides the above specification
devolving to C<wget>, and the latter overrides the default wget
-arguments, which are: C<--tries=8 --timeout=60 -q -O>.
+arguments.
C<TL_DOWNLOAD_ARGS> must be defined so that the file the output goes to
is the first argument after the C<TL_DOWNLOAD_ARGS>. Thus, typically it
@@ -2225,7 +2225,8 @@ sub download_file {
return($ret);
}
-sub _download_file {
+sub _download_file
+{
my ($url, $dest, $wgetdefault) = @_;
if (win32()) {
$dest =~ s!/!\\!g;
@@ -2233,7 +2234,7 @@ sub _download_file {
my $wget = $ENV{"TL_DOWNLOAD_PROGRAM"} || $wgetdefault;
my $wgetargs = $ENV{"TL_DOWNLOAD_ARGS"}
- || "--tries=10 --timeout=90 -q -O";
+ || "--user-agent=texlive tries=10 --timeout=90 -q -O";
debug("downloading $url using $wget $wgetargs\n");
my $ret;