aboutsummaryrefslogtreecommitdiff
path: root/src/libstore/build.cc
diff options
context:
space:
mode:
authorEelco Dolstra <edolstra@gmail.com>2020-01-06 22:18:00 +0100
committerEelco Dolstra <edolstra@gmail.com>2020-01-06 22:20:10 +0100
commitbc22a7ee6a6d9367f3197cf31a5fdd477b155974 (patch)
treee6835eab2387c466d0451db7eb4189909f8ca2a0 /src/libstore/build.cc
parente2988f48a1354e4d679137acf2d3c44559a988e8 (diff)
Fix use of uninitialized store path
Fixes 'building of '/nix/store/00000000000000000000000000000000-': ...'.
Diffstat (limited to 'src/libstore/build.cc')
-rw-r--r--src/libstore/build.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libstore/build.cc b/src/libstore/build.cc
index 4c07865e9..e1171082b 100644
--- a/src/libstore/build.cc
+++ b/src/libstore/build.cc
@@ -1016,7 +1016,7 @@ DerivationGoal::DerivationGoal(StorePath && drvPath, const StringSet & wantedOut
, buildMode(buildMode)
{
state = &DerivationGoal::getDerivation;
- name = fmt("building of '%s'", worker.store.printStorePath(drvPath));
+ name = fmt("building of '%s'", worker.store.printStorePath(this->drvPath));
trace("created");
mcExpectedBuilds = std::make_unique<MaintainCount<uint64_t>>(worker.expectedBuilds);
@@ -1041,7 +1041,7 @@ DerivationGoal::DerivationGoal(StorePath && drvPath, const BasicDerivation & drv
/* Prevent the .chroot directory from being
garbage-collected. (See isActiveTempFile() in gc.cc.) */
- worker.store.addTempRoot(drvPath);
+ worker.store.addTempRoot(this->drvPath);
}
@@ -4259,7 +4259,7 @@ SubstitutionGoal::SubstitutionGoal(StorePath && storePath, Worker & worker, Repa
, repair(repair)
{
state = &SubstitutionGoal::init;
- name = fmt("substitution of '%s'", worker.store.printStorePath(storePath));
+ name = fmt("substitution of '%s'", worker.store.printStorePath(this->storePath));
trace("created");
maintainExpectedSubstitutions = std::make_unique<MaintainCount<uint64_t>>(worker.expectedSubstitutions);
}