forked from ungleich-public/ccollect
fix endless loop
This commit is contained in:
parent
0d5cc4ddbc
commit
8ace2a6520
1 changed files with 5 additions and 3 deletions
|
@ -451,18 +451,20 @@ while [ "${i}" -lt "${no_sources}" ]; do
|
||||||
|
|
||||||
i=0
|
i=0
|
||||||
while read incomplete; do
|
while read incomplete; do
|
||||||
eva incomplete_$i=$(echo ${incomplete} | sed "s/\\.${c_marker}\$//")
|
eval incomplete_$i=\"$(echo ${incomplete} | sed "s/\\.${c_marker}\$//")\"
|
||||||
i=$(($i+1))
|
i=$(($i+1))
|
||||||
done < "${TMP}"
|
done < "${TMP}"
|
||||||
|
|
||||||
while [ $i -gt 0 ]; do
|
j=0
|
||||||
eval realincomplete=\"incomplete_$i\"
|
while [ "$j" -lt "$i" ]; do
|
||||||
|
eval realincomplete=\"\$incomplete_$i\"
|
||||||
_techo "Incomplete backup: ${realincomplete}"
|
_techo "Incomplete backup: ${realincomplete}"
|
||||||
if [ "${DELETE_INCOMPLETE}" = "yes" ]; then
|
if [ "${DELETE_INCOMPLETE}" = "yes" ]; then
|
||||||
_techo "Deleting ${realincomplete} ..."
|
_techo "Deleting ${realincomplete} ..."
|
||||||
pcmd rm $VVERBOSE -rf "${ddir}/${realincomplete}" || \
|
pcmd rm $VVERBOSE -rf "${ddir}/${realincomplete}" || \
|
||||||
_exit_err "Removing ${realincomplete} failed."
|
_exit_err "Removing ${realincomplete} failed."
|
||||||
fi
|
fi
|
||||||
|
i=$((i+i))
|
||||||
done
|
done
|
||||||
|
|
||||||
#
|
#
|
||||||
|
|
Loading…
Reference in a new issue