summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorP. J. McDermott <pjm@nac.net>2013-07-27 15:26:04 (EDT)
committer P. J. McDermott <pjm@nac.net>2013-07-27 15:26:04 (EDT)
commit921b0f76ec1e67f306877465356b324b771d7f3d (patch)
tree0e872832816d86b18a91e3eede5c521eecd938bf
parent3f42e8b534cd16413d8ec4412c3c00c91145e1cf (diff)
collect_garbage(): Verify expansion of pathname.
-rw-r--r--lib/garbage.sh3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/garbage.sh b/lib/garbage.sh
index 2862ad9..dcec7ed 100644
--- a/lib/garbage.sh
+++ b/lib/garbage.sh
@@ -32,6 +32,9 @@ collect_garbage()
cur_time=$(date '+%s')
for garbage in "${archive}/.db/garbage/"*; do
+ if [ ! -f "${garbage}" ]; then
+ continue
+ fi
gar_time=${garbage##*/}
if [ ${cur_time} -lt ${gar_time} ]; then
break