about summary refs log tree commit diff
path: root/src/libstore
diff options
context:
space:
mode:
authorEelco Dolstra <e.dolstra@tudelft.nl>2011-12-30T17·13+0000
committerEelco Dolstra <e.dolstra@tudelft.nl>2011-12-30T17·13+0000
commita71d02440b03cdb5dad6e43f786c0cc86cbb87b1 (patch)
tree992e58af26b8466b3b72986cfb0db2c5059d62e6 /src/libstore
parent6f5e3326cef2a2049c8f4ea757accafe4fc9d53f (diff)
* Oops.
Diffstat (limited to 'src/libstore')
-rw-r--r--src/libstore/misc.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libstore/misc.cc b/src/libstore/misc.cc
index abe59d1628fb..4ac0afe844b6 100644
--- a/src/libstore/misc.cc
+++ b/src/libstore/misc.cc
@@ -103,10 +103,10 @@ static void dfsVisit(StoreAPI & store, const PathSet & paths,
 {
     if (parents.find(path) != parents.end())
         throw BuildError(format("cycle detected in the references of `%1%'") % path);
-    parents.insert(path);
     
     if (visited.find(path) != visited.end()) return;
     visited.insert(path);
+    parents.insert(path);
     
     PathSet references;
     if (store.isValidPath(path))