about summary refs log tree commit diff
path: root/src/libstore/gc.cc
diff options
context:
space:
mode:
authorEelco Dolstra <eelco.dolstra@logicblox.com>2016-02-24T16·44+0100
committerEelco Dolstra <eelco.dolstra@logicblox.com>2016-02-24T16·44+0100
commit152b1d6bf9c89b4db9848475e3000821e159d479 (patch)
tree2667ff6b2f8f91269fbb3a12fee4aa2fc53bdd04 /src/libstore/gc.cc
parent28e7e29abdcdaf60ba8a5fad3738fe4a8f3db9a8 (diff)
deletePath(): Succeed if path doesn't exist
Also makes it robust against concurrent deletions.
Diffstat (limited to 'src/libstore/gc.cc')
-rw-r--r--src/libstore/gc.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libstore/gc.cc b/src/libstore/gc.cc
index 1bc8d162f837..e082f67143a3 100644
--- a/src/libstore/gc.cc
+++ b/src/libstore/gc.cc
@@ -608,7 +608,7 @@ void LocalStore::collectGarbage(const GCOptions & options, GCResults & results)
 
     state.shouldDelete = options.action == GCOptions::gcDeleteDead || options.action == GCOptions::gcDeleteSpecific;
 
-    if (state.shouldDelete && pathExists(reservedPath))
+    if (state.shouldDelete)
         deletePath(reservedPath);
 
     /* Acquire the global GC root.  This prevents