summaryrefslogtreecommitdiffstats
path: root/urpm/download.pm
diff options
context:
space:
mode:
authorRafael Garcia-Suarez <rgarciasuarez@mandriva.org>2005-02-16 10:36:49 +0000
committerRafael Garcia-Suarez <rgarciasuarez@mandriva.org>2005-02-16 10:36:49 +0000
commit34ef3a5af93540ae61c8d69a33e02004e5d0634c (patch)
tree1e643987ffa6cdc092661255dc28dbede5bb246e /urpm/download.pm
parentd1f85e8cbfde8d82aa336c72b0e43ea2c6d92ac4 (diff)
downloadurpmi-34ef3a5af93540ae61c8d69a33e02004e5d0634c.tar
urpmi-34ef3a5af93540ae61c8d69a33e02004e5d0634c.tar.gz
urpmi-34ef3a5af93540ae61c8d69a33e02004e5d0634c.tar.bz2
urpmi-34ef3a5af93540ae61c8d69a33e02004e5d0634c.tar.xz
urpmi-34ef3a5af93540ae61c8d69a33e02004e5d0634c.zip
Remove curl 7.12.2 bug workaround
Diffstat (limited to 'urpm/download.pm')
-rw-r--r--urpm/download.pm8
1 files changed, 4 insertions, 4 deletions
diff --git a/urpm/download.pm b/urpm/download.pm
index 23b2d273..8de73e07 100644
--- a/urpm/download.pm
+++ b/urpm/download.pm
@@ -341,15 +341,15 @@ sub sync_curl {
$file = shift @l;
propagate_sync_callback($options, 'start', $file);
}
- if (my ($percent, $total, $eta, $speed) = $buf =~ /^\s*(\d+)\s+(\S+)[^\r\n]*\s+(\S+)\s+-?(\S+)\s*[\r\n]$/ms) {
+ if (my ($percent, $total, $eta, $speed) = $buf =~ /^\s*(\d+)\s+(\S+)[^\r\n]*\s+(\S+)\s+(\S+)\s*[\r\n]$/ms) {
+ $speed =~ s/^-//;
if (propagate_sync_callback($options, 'progress', $file, $percent, $total, $eta, $speed) eq 'canceled') {
kill 15, $curl_pid;
close $curl;
return;
}
- #- this regexp checks that download has actually started
- #- (work around a bug in curl 7.12.2 output when 302 answers are involved)
- if ($_ eq "\n" && ($percent == 100 || $buf !~ /--:--:--/)) {
+ #- this checks that download has actually started
+ if ($_ eq "\n") {
propagate_sync_callback($options, 'end', $file);
$file = undef;
}