diff options
author | Marius Bakke <mbakke@fastmail.com> | 2020-01-12 20:57:38 +0100 |
---|---|---|
committer | Marius Bakke <mbakke@fastmail.com> | 2020-01-12 20:57:38 +0100 |
commit | 8f1ab291bca31e84bec50da4374175367d498a6f (patch) | |
tree | e96a6f7a44382646733ac08ecaccb2f57182f017 /nix/libutil/util.hh | |
parent | f0bce2e08feb157b3d8b5100b1ea26bbbd6141e3 (diff) | |
parent | 2e4bb89354d909b661208b3900abfeaa621a1582 (diff) |
Merge branch 'master' into staging
Diffstat (limited to 'nix/libutil/util.hh')
-rw-r--r-- | nix/libutil/util.hh | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/nix/libutil/util.hh b/nix/libutil/util.hh index 6a6e07c478..9e3c14bdd4 100644 --- a/nix/libutil/util.hh +++ b/nix/libutil/util.hh @@ -94,10 +94,12 @@ 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. */ + returns the number of bytes and blocks freed, and 'linkThreshold' denotes + the number of links under which a file is accounted for in 'bytesFreed'. */ void deletePath(const Path & path); -void deletePath(const Path & path, unsigned long long & bytesFreed); +void deletePath(const Path & path, unsigned long long & bytesFreed, + size_t linkThreshold = 1); /* Create a temporary directory. */ Path createTempDir(const Path & tmpRoot = "", const Path & prefix = "nix", |