diff options
Diffstat (limited to 'src/libfetchers/fetchers.cc')
-rw-r--r-- | src/libfetchers/fetchers.cc | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/libfetchers/fetchers.cc b/src/libfetchers/fetchers.cc index e6741a451..916e0a8e8 100644 --- a/src/libfetchers/fetchers.cc +++ b/src/libfetchers/fetchers.cc @@ -132,7 +132,14 @@ std::pair<Tree, Input> Input::fetch(ref<Store> store) const } } - auto [tree, input] = scheme->fetch(store, *this); + auto [tree, input] = [&]() -> std::pair<Tree, Input> { + try { + return scheme->fetch(store, *this); + } catch (Error & e) { + e.addTrace({}, "while fetching the input '%s'", to_string()); + throw; + } + }(); if (tree.actualPath == "") tree.actualPath = store->toRealPath(tree.storePath); |