aboutsummaryrefslogtreecommitdiff
path: root/src/libstore/build/derivation-goal.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/libstore/build/derivation-goal.cc')
-rw-r--r--src/libstore/build/derivation-goal.cc8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/libstore/build/derivation-goal.cc b/src/libstore/build/derivation-goal.cc
index 5de159b2d..765df5f5a 100644
--- a/src/libstore/build/derivation-goal.cc
+++ b/src/libstore/build/derivation-goal.cc
@@ -127,11 +127,15 @@ Goal::WorkResult DerivationGoal::timedOut(Error && ex)
kj::Promise<Result<Goal::WorkResult>> DerivationGoal::workImpl() noexcept
{
- return (useDerivation ? getDerivation() : haveDerivation()).attach(kj::defer([this] {
+ KJ_DEFER({
act.reset();
actLock.reset();
builderActivities.clear();
- }));
+ });
+
+ BOOST_OUTCOME_CO_TRY(auto result, co_await (useDerivation ? getDerivation() : haveDerivation()));
+ result.storePath = drvPath;
+ co_return result;
}
bool DerivationGoal::addWantedOutputs(const OutputsSpec & outputs)