From a3f205b24954c7f0983a937b0b9b3d64c22a2fa7 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Wed, 3 Oct 2012 10:38:09 -0400 Subject: When repairing a derivation, check and repair the entire output closure If we find a corrupted path in the output closure, we rebuild the derivation that produced that particular path. --- src/libstore/local-store.hh | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/libstore/local-store.hh') diff --git a/src/libstore/local-store.hh b/src/libstore/local-store.hh index 00356bf9d7bf..b2f06d8118ca 100644 --- a/src/libstore/local-store.hh +++ b/src/libstore/local-store.hh @@ -206,6 +206,8 @@ public: contents. */ bool pathContentsGood(const Path & path); + void markContentsGood(const Path & path); + private: Path schemaPath; @@ -233,6 +235,9 @@ private: SQLiteStmt stmtQueryDerivationOutputs; SQLiteStmt stmtQueryPathFromHashPart; + /* Cache for pathContentsGood(). */ + std::map pathContentsGoodCache; + int getSchema(); void openDB(bool create); -- cgit 1.4.1