From 1b591a040c27f6886c074ed4de722692ac9e05a0 Mon Sep 17 00:00:00 2001 From: Nico Schottelius Date: Sat, 31 Oct 2009 07:31:23 +0100 Subject: [PATCH] -p is not needed, when matching directories with */ Signed-off-by: Nico Schottelius --- ccollect.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ccollect.sh b/ccollect.sh index 5697003..6395004 100755 --- a/ccollect.sh +++ b/ccollect.sh @@ -458,7 +458,8 @@ while [ "${i}" -lt "${no_sources}" ]; do # # Check: maximum number of backups is reached? # - count="$(pcmd ls -p1 "${ddir}/${INTERVAL}.*/" | wc -l \ + + count="$(pcmd ls -1 "${ddir}/${INTERVAL}.*/" | wc -l \ | sed 's/^ *//g')" || _exit_err "Counting backups failed" _techo "Existing backups: ${count} Total keeping backups: ${c_interval}"