summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoel Rosdahl <joel@rosdahl.net>2018-04-23 21:44:56 +0200
committerJoel Rosdahl <joel@rosdahl.net>2018-04-23 21:51:11 +0200
commit9a71ae4d8a20b44c0588d1b5d83109653930f28e (patch)
tree44d52db87afb9431603ef4bbd36234fdf47b5aa1
parent331d2e0334fcc294fbd6ecccdc7fbd0479909eec (diff)
downloadccache-9a71ae4d8a20b44c0588d1b5d83109653930f28e.tar.gz
Remove irrelevant variable assignment in wipe_dir
-rw-r--r--src/cleanup.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/cleanup.c b/src/cleanup.c
index 8c46eac5..c6273ecd 100644
--- a/src/cleanup.c
+++ b/src/cleanup.c
@@ -236,11 +236,10 @@ static void wipe_fn(const char *fname, struct stat *st)
// Wipe one cache subdirectory.
void
-wipe_dir(struct conf *conf, const char *dir)
+wipe_dir(const char *dir)
{
cc_log("Clearing out cache directory %s", dir);
- files_in_cache_threshold = conf->max_files * conf->limit_multiple / 16;
files_in_cache = 0;
traverse(dir, wipe_fn);
@@ -258,7 +257,7 @@ void wipe_all(struct conf *conf)
{
for (int i = 0; i <= 0xF; i++) {
char *dname = format("%s/%1x", conf->cache_dir, i);
- wipe_dir(conf, dname);
+ wipe_dir(dname);
free(dname);
}