aboutsummaryrefslogtreecommitdiff
path: root/src/libstore
diff options
context:
space:
mode:
authorEelco Dolstra <edolstra@gmail.com>2018-02-09 14:36:38 +0100
committerEelco Dolstra <edolstra@gmail.com>2018-02-09 15:06:47 +0100
commitaa02cdc33ceccce35e56d61535fdb2c55f13cc44 (patch)
tree5ad22f21d5ba1e63fc06019c2f23c0e94e7bfd5a /src/libstore
parent3d2d207aadb8e93760a9e417392208266f9985a3 (diff)
getDefaultSubstituters(): Skip broken substituters
Fixes #1340.
Diffstat (limited to 'src/libstore')
-rw-r--r--src/libstore/store-api.cc6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/libstore/store-api.cc b/src/libstore/store-api.cc
index 7abb300a9..4d43ef082 100644
--- a/src/libstore/store-api.cc
+++ b/src/libstore/store-api.cc
@@ -896,7 +896,11 @@ std::list<ref<Store>> getDefaultSubstituters()
auto addStore = [&](const std::string & uri) {
if (done.count(uri)) return;
done.insert(uri);
- stores.push_back(openStore(uri));
+ try {
+ stores.push_back(openStore(uri));
+ } catch (Error & e) {
+ printError("warning: %s", e.what());
+ }
};
for (auto uri : settings.substituters.get())