summaryrefslogtreecommitdiffstats
path: root/urpm
diff options
context:
space:
mode:
authorRafael Garcia-Suarez <rgarciasuarez@mandriva.org>2005-10-27 10:02:24 +0000
committerRafael Garcia-Suarez <rgarciasuarez@mandriva.org>2005-10-27 10:02:24 +0000
commit68258b087964a1dfd272be12f8aa2b7ea4c36642 (patch)
tree44cb5ad065bacf0ba7085e76d022c20c18d2abd6 /urpm
parent5a95dd19835e18285e4849fae21135d48f9c7839 (diff)
downloadurpmi-68258b087964a1dfd272be12f8aa2b7ea4c36642.tar
urpmi-68258b087964a1dfd272be12f8aa2b7ea4c36642.tar.gz
urpmi-68258b087964a1dfd272be12f8aa2b7ea4c36642.tar.bz2
urpmi-68258b087964a1dfd272be12f8aa2b7ea4c36642.tar.xz
urpmi-68258b087964a1dfd272be12f8aa2b7ea4c36642.zip
Report curl download errors on ftp or on cancellation more agressively, so the
urpm routines can recover properly.
Diffstat (limited to 'urpm')
-rw-r--r--urpm/download.pm5
1 files changed, 3 insertions, 2 deletions
diff --git a/urpm/download.pm b/urpm/download.pm
index d18f0395..78494081 100644
--- a/urpm/download.pm
+++ b/urpm/download.pm
@@ -307,7 +307,8 @@ sub sync_curl {
};
}
}
- close $curl;
+ close $curl
+ or die N("curl failed: exited with %d or signal %d\n", $? >> 8, $? & 127);
#- now analyse size and time stamp according to what already exists here.
if (@ftp_files) {
@@ -367,7 +368,7 @@ sub sync_curl {
if (propagate_sync_callback($options, 'progress', $file, $percent, $total, $eta, $speed) eq 'canceled') {
kill 15, $curl_pid;
close $curl;
- return;
+ die N("curl failed: download canceled\n");
}
#- this checks that download has actually started
if ($_ eq "\n"