summaryrefslogtreecommitdiff
path: root/methods
diff options
context:
space:
mode:
authorDavid Kalnischkies <david@kalnischkies.de>2016-07-06 15:10:52 +0200
committerDavid Kalnischkies <david@kalnischkies.de>2016-07-06 15:53:59 +0200
commitb50dfa6b2dd2d459e0c2746ac9367982b96ffac0 (patch)
tree25d701de638b3f5adc9ec072d11d6724057a5317 /methods
parent3465138575e1fd0d5892d9b6be1ae232eb873460 (diff)
report all instead of first error up the acquire chain
If we don't give a specific error to report up it is likely that all error currently in the error stack are equally important, so reporting just one could turn out to be confusing e.g. if name resolution failed in a SRV record list.
Diffstat (limited to 'methods')
-rw-r--r--methods/https.cc8
1 files changed, 7 insertions, 1 deletions
diff --git a/methods/https.cc b/methods/https.cc
index 92f786d17..bbdbd8fa9 100644
--- a/methods/https.cc
+++ b/methods/https.cc
@@ -436,7 +436,13 @@ bool HttpsMethod::Fetch(FetchItem *Itm)
break;
}
#pragma GCC diagnostic pop
- return _error->Error("%s", curl_errorstr);
+ // only take curls technical errors if we haven't our own
+ // (e.g. for the maximum size limit we have and curls can be confusing)
+ if (_error->PendingError() == false)
+ _error->Error("%s", curl_errorstr);
+ else
+ _error->Warning("curl: %s", curl_errorstr);
+ return false;
}
// server says file not modified