summaryrefslogtreecommitdiffstats
path: root/urpm/download.pm
diff options
context:
space:
mode:
Diffstat (limited to 'urpm/download.pm')
-rw-r--r--urpm/download.pm5
1 files changed, 4 insertions, 1 deletions
diff --git a/urpm/download.pm b/urpm/download.pm
index 27319bf3..41bfa848 100644
--- a/urpm/download.pm
+++ b/urpm/download.pm
@@ -127,7 +127,10 @@ sub sync_wget {
if ($_ eq "\r" || $_ eq "\n") {
if ($options->{callback}) {
if ($buf =~ /^--\d\d:\d\d:\d\d--\s+(\S.*)\n/ms) {
- $file && $file ne $1 and propagate_sync_callback($options, 'end', $file);
+ if ($file && $file ne $1) {
+ propagate_sync_callback($options, 'end', $file);
+ undef $file;
+ }
! defined $file and propagate_sync_callback($options, 'start', $file = $1);
} elsif (defined $file && ! defined $total && $buf =~ /==>\s+RETR/) {
$total = '';