aboutsummaryrefslogtreecommitdiff
path: root/src/libutil/util.hh
diff options
context:
space:
mode:
authorEelco Dolstra <eelco.dolstra@logicblox.com>2016-02-24 17:44:12 +0100
committerEelco Dolstra <eelco.dolstra@logicblox.com>2016-02-24 17:44:55 +0100
commit152b1d6bf9c89b4db9848475e3000821e159d479 (patch)
tree2667ff6b2f8f91269fbb3a12fee4aa2fc53bdd04 /src/libutil/util.hh
parent28e7e29abdcdaf60ba8a5fad3738fe4a8f3db9a8 (diff)
deletePath(): Succeed if path doesn't exist
Also makes it robust against concurrent deletions.
Diffstat (limited to 'src/libutil/util.hh')
-rw-r--r--src/libutil/util.hh4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/libutil/util.hh b/src/libutil/util.hh
index 9eebb67fd..3606f6ec9 100644
--- a/src/libutil/util.hh
+++ b/src/libutil/util.hh
@@ -92,8 +92,8 @@ string readLine(int fd);
void writeLine(int fd, string s);
/* Delete a path; i.e., in the case of a directory, it is deleted
- recursively. Don't use this at home, kids. The second variant
- returns the number of bytes and blocks freed. */
+ recursively. It's not an error if the path does not exist. The
+ second variant returns the number of bytes and blocks freed. */
void deletePath(const Path & path);
void deletePath(const Path & path, unsigned long long & bytesFreed);