also move the interval check further to the beginning

Signed-off-by: Nico Schottelius <nico@ikn.schottelius.org>
This commit is contained in:
Nico Schottelius 2009-11-01 15:28:33 +01:00
parent ccf86defaf
commit f98853379e

View file

@ -324,6 +324,19 @@ while [ "${source_no}" -lt "${no_sources}" ]; do
fi fi
done done
#
# Interval definition: First try source specific, fallback to default
#
c_interval="$(cat "${backup}/intervals/${INTERVAL}" 2>/dev/null)"
if [ -z "${c_interval}" ]; then
c_interval="$(cat "${CDEFAULTS}/intervals/${INTERVAL}" 2>/dev/null)"
if [ -z "${c_interval}" ]; then
_exit_err "No definition for interval \"${INTERVAL}\" found. Skipping."
fi
fi
# #
# Sort by ctime (default) or mtime (configuration option) # Sort by ctime (default) or mtime (configuration option)
# #
@ -446,19 +459,6 @@ while [ "${source_no}" -lt "${no_sources}" ]; do
fi fi
fi fi
#
# Interval definition: First try source specific, fallback to default
#
c_interval="$(cat "${backup}/intervals/${INTERVAL}" 2>/dev/null)"
if [ -z "${c_interval}" ]; then
c_interval="$(cat "${CDEFAULTS}/intervals/${INTERVAL}" 2>/dev/null)"
if [ -z "${c_interval}" ]; then
_exit_err "No definition for interval \"${INTERVAL}\" found. Skipping."
fi
fi
# #
# Check: maximum number of backups is reached? # Check: maximum number of backups is reached?
# #