diff options
author | Eelco Dolstra <eelco.dolstra@logicblox.com> | 2016-06-01 14:49:12 +0200 |
---|---|---|
committer | Eelco Dolstra <eelco.dolstra@logicblox.com> | 2016-06-01 16:24:17 +0200 |
commit | 7850d3d27910c30232dd09dd86ee8afdaad26b90 (patch) | |
tree | da539f14d98d815e89b6ad60ed8e1e1ab9981cbf /src/libstore/local-binary-cache-store.cc | |
parent | 1b5b654fe25cf7f2219ebe96a943397d683bfa0e (diff) |
Make the store directory a member variable of Store
Diffstat (limited to 'src/libstore/local-binary-cache-store.cc')
-rw-r--r-- | src/libstore/local-binary-cache-store.cc | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/libstore/local-binary-cache-store.cc b/src/libstore/local-binary-cache-store.cc index b418c9c04..bdc80cf90 100644 --- a/src/libstore/local-binary-cache-store.cc +++ b/src/libstore/local-binary-cache-store.cc @@ -13,7 +13,7 @@ private: public: LocalBinaryCacheStore( - const StoreParams & params, const Path & binaryCacheDir) + const Params & params, const Path & binaryCacheDir) : BinaryCacheStore(params) , binaryCacheDir(binaryCacheDir) { @@ -45,7 +45,7 @@ protected: if (entry.name.size() != 40 || !hasSuffix(entry.name, ".narinfo")) continue; - paths.insert(settings.nixStore + "/" + entry.name.substr(0, entry.name.size() - 8)); + paths.insert(storeDir + "/" + entry.name.substr(0, entry.name.size() - 8)); } return paths; @@ -59,7 +59,7 @@ void LocalBinaryCacheStore::init() BinaryCacheStore::init(); if (diskCache && !diskCache->cacheExists(getUri())) - diskCache->createCache(getUri(), wantMassQuery_, priority); + diskCache->createCache(getUri(), storeDir, wantMassQuery_, priority); } static void atomicWrite(const Path & path, const std::string & s) @@ -93,7 +93,7 @@ std::shared_ptr<std::string> LocalBinaryCacheStore::getFile(const std::string & } static RegisterStoreImplementation regStore([]( - const std::string & uri, const StoreParams & params) + const std::string & uri, const Store::Params & params) -> std::shared_ptr<Store> { if (std::string(uri, 0, 7) != "file://") return 0; |