diff options
author | Christophe Fergeau <cfergeau@mandriva.com> | 2009-06-04 16:07:25 +0000 |
---|---|---|
committer | Christophe Fergeau <cfergeau@mandriva.com> | 2009-06-04 16:07:25 +0000 |
commit | 494e132262dc7c0a161b4e3df5765f293d483574 (patch) | |
tree | 6fc7d6841ace752acb4417fa58919d313014663c /urpm | |
parent | 3627f98261a61ba19abc6e92efacbd5101803b81 (diff) | |
download | urpmi-494e132262dc7c0a161b4e3df5765f293d483574.tar urpmi-494e132262dc7c0a161b4e3df5765f293d483574.tar.gz urpmi-494e132262dc7c0a161b4e3df5765f293d483574.tar.bz2 urpmi-494e132262dc7c0a161b4e3df5765f293d483574.tar.xz urpmi-494e132262dc7c0a161b4e3df5765f293d483574.zip |
- adjust parsing of aria2 output for aria2 1.4, fixes bug #51354
Diffstat (limited to 'urpm')
-rw-r--r-- | urpm/download.pm | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/urpm/download.pm b/urpm/download.pm index 63478f26..a2669919 100644 --- a/urpm/download.pm +++ b/urpm/download.pm @@ -723,7 +723,8 @@ sub _parse_aria2_output { propagate_sync_callback($options, 'start', $file) if !$options->{is_retry}; } - if ($buf =~ m!^\[#\d*\s+\S+:([\d\.]+\w*).([\d\.]+\w*)\S([\d]+)\S+\s+\S+\s*([\d\.]+)\s\w*:([\d\.]+\w*/\w)\s\w*:(\d+\w*)\]$!) { + #parses aria2c: [#1 SIZE:176.0KiB/2.5MiB(6%) CN:3 SPD:256.22KiBs ETA:09s] + if ($buf =~ m!^\[#\d*\s+\S+:([\d\.]+\w*).([\d\.]+\w*)\S([\d]+)\S+\s+\S+\s*([\d\.]+)\s\w*:([\d\.]+\w*)\s\w*:(\d+\w*)\]$!) { my ($total, $percent, $speed, $eta) = ($2, $3, $5, $6); #- $1 = current downloaded size, $4 = connections if (propagate_sync_callback($options, 'progress', $file, $percent, $total, $eta, $speed) eq 'canceled') { |