diff options
author | Rafael Garcia-Suarez <rgarciasuarez@mandriva.org> | 2005-12-02 15:21:14 +0000 |
---|---|---|
committer | Rafael Garcia-Suarez <rgarciasuarez@mandriva.org> | 2005-12-02 15:21:14 +0000 |
commit | 79da5f7c7fabfefd8295395f9e2c8fd57e58e43e (patch) | |
tree | 1a50296029e9378747b7f181a1c00a127f1011ac | |
parent | d4520fb13b45e431c7c6c38716b626534bc30bd5 (diff) | |
download | urpmi-79da5f7c7fabfefd8295395f9e2c8fd57e58e43e.tar urpmi-79da5f7c7fabfefd8295395f9e2c8fd57e58e43e.tar.gz urpmi-79da5f7c7fabfefd8295395f9e2c8fd57e58e43e.tar.bz2 urpmi-79da5f7c7fabfefd8295395f9e2c8fd57e58e43e.tar.xz urpmi-79da5f7c7fabfefd8295395f9e2c8fd57e58e43e.zip |
Fix download with wget, broken by latest changes
-rw-r--r-- | urpm/download.pm | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/urpm/download.pm b/urpm/download.pm index afde787e..92c35945 100644 --- a/urpm/download.pm +++ b/urpm/download.pm @@ -207,7 +207,7 @@ sub sync_wget { my $cwd = getcwd(); chdir $options->{dir}; my ($buf, $total, $file) = ('', undef, undef); - my $wget_pid = open my $wget, join(" ", map { "'$_'" } + my $wget_command = join(" ", map { "'$_'" } #- construction of the wget command-line "/usr/bin/wget", ($options->{limit_rate} ? "--limit-rate=$options->{limit_rate}" : ()), @@ -219,11 +219,12 @@ sub sync_wget { "--retr-symlinks", "--no-check-certificate", "--timeout=$CONNECT_TIMEOUT", - "-NP", + "-N", (defined $options->{'wget-options'} ? split /\s+/, $options->{'wget-options'} : ()), - $options->{dir}, + '-P', $options->{dir}, @_ ) . " |"; + my $wget_pid = open my $wget, $wget_command; local $/ = \1; #- read input by only one char, this is slow but very nice (and it works!). while (<$wget>) { $buf .= $_; |