aboutsummaryrefslogtreecommitdiff
path: root/src/libstore/binary-cache-store.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/libstore/binary-cache-store.cc')
-rw-r--r--src/libstore/binary-cache-store.cc50
1 files changed, 22 insertions, 28 deletions
diff --git a/src/libstore/binary-cache-store.cc b/src/libstore/binary-cache-store.cc
index ac41add2c..9058bb8b1 100644
--- a/src/libstore/binary-cache-store.cc
+++ b/src/libstore/binary-cache-store.cc
@@ -307,17 +307,15 @@ StorePath BinaryCacheStore::addToStoreFromDump(Source & dump, std::string_view n
return addToStoreCommon(dump, repair, CheckSigs, [&](HashResult nar) {
ValidPathInfo info {
*this,
- {
- .name = std::string { name },
- .info = FixedOutputInfo {
- {
- .method = method,
- .hash = nar.first,
- },
- .references = {
- .others = references,
- .self = false,
- },
+ name,
+ FixedOutputInfo {
+ {
+ .method = method,
+ .hash = nar.first,
+ },
+ .references = {
+ .others = references,
+ .self = false,
},
},
nar.first,
@@ -427,17 +425,15 @@ StorePath BinaryCacheStore::addToStore(
return addToStoreCommon(*source, repair, CheckSigs, [&](HashResult nar) {
ValidPathInfo info {
*this,
- {
- .name = std::string { name },
- .info = FixedOutputInfo {
- {
- .method = method,
- .hash = h,
- },
- .references = {
- .others = references,
- .self = false,
- },
+ name,
+ FixedOutputInfo {
+ {
+ .method = method,
+ .hash = h,
+ },
+ .references = {
+ .others = references,
+ .self = false,
},
},
nar.first,
@@ -465,12 +461,10 @@ StorePath BinaryCacheStore::addTextToStore(
return addToStoreCommon(source, repair, CheckSigs, [&](HashResult nar) {
ValidPathInfo info {
*this,
- {
- .name = std::string { name },
- .info = TextInfo {
- { .hash = textHash },
- references,
- },
+ std::string { name },
+ TextInfo {
+ { .hash = textHash },
+ references,
},
nar.first,
};