libstore: don't wrap&unwrap connection handles
this was only necessary for old protocols we no longer support. Change-Id: Iebb06ce6266c2c7c3f97da469b1295f4cb54ee5a
This commit is contained in:
@@ -359,8 +359,7 @@ kj::Promise<Result<ref<const ValidPathInfo>>> RemoteStore::addCAToStore(
|
||||
const StorePathSet & references,
|
||||
RepairFlag repair)
|
||||
try {
|
||||
std::optional<ConnectionHandle> conn_(TRY_AWAIT(getConnection()));
|
||||
auto & conn = *conn_;
|
||||
auto conn(TRY_AWAIT(getConnection()));
|
||||
|
||||
conn->to
|
||||
<< WorkerProto::Op::AddToStore
|
||||
@@ -523,8 +522,7 @@ kj::Promise<Result<std::vector<KeyedBuildResult>>> RemoteStore::buildPathsWithRe
|
||||
try {
|
||||
TRY_AWAIT(copyDrvsFromEvalStore(paths, evalStore));
|
||||
|
||||
std::optional<ConnectionHandle> conn_(TRY_AWAIT(getConnection()));
|
||||
auto & conn = *conn_;
|
||||
auto conn(TRY_AWAIT(getConnection()));
|
||||
|
||||
conn->to << WorkerProto::Op::BuildPathsWithResults;
|
||||
conn->to << WorkerProto::write(*this, *conn, paths);
|
||||
|
||||
Reference in New Issue
Block a user