summaryrefslogtreecommitdiff
path: root/support/htcacheclean.c
diff options
context:
space:
mode:
authorGraham Leggett <minfrin@apache.org>2010-09-29 15:41:15 +0000
committerGraham Leggett <minfrin@apache.org>2010-09-29 15:41:15 +0000
commit8dd0a17fa3054acf30a35bb419ff2b96384b7f9a (patch)
treebc1aa49630e37bc3c47ff76373198736293736de /support/htcacheclean.c
parent0b57e95fe472c8cd94e51a1583a2f22fdbc7c0f1 (diff)
downloadhttpd-8dd0a17fa3054acf30a35bb419ff2b96384b7f9a.tar.gz
htcacheclean: If the cache file format is unrecognised, remove the entry
from the cache. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1002686 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'support/htcacheclean.c')
-rw-r--r--support/htcacheclean.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/support/htcacheclean.c b/support/htcacheclean.c
index 72983ce558..fef8e854da 100644
--- a/support/htcacheclean.c
+++ b/support/htcacheclean.c
@@ -509,6 +509,12 @@ static int process_dir(char *path, apr_pool_t *pool)
p);
break;
}
+ else {
+ /* We didn't recognise the format, kill the files */
+ apr_file_close(fd);
+ delete_entry(path, d->basename, p);
+ break;
+ }
}
else {
apr_file_close(fd);