Make sure that a backup exists before attempting any action which reads the file list from it.
Signed-off-by: Jean Delvare <[email protected]> Reviewed-by: Raphael Hertzog <[email protected]> --- quilt/scripts/backup-files.in | 5 +++++ 1 file changed, 5 insertions(+) --- a/quilt/scripts/backup-files.in +++ b/quilt/scripts/backup-files.in @@ -205,6 +205,11 @@ if [ "${OPT_PREFIX:(-1)}" != / ]; then exit 1 fi +if [ "$1" = - ] && [ ! -d "$OPT_PREFIX" ]; then + echo "Backup is missing" >&2 + exit 1 +fi + if [ -n "$OPT_FILE" ]; then cat "$OPT_FILE" \ | while read nextfile; do _______________________________________________ Quilt-dev mailing list [email protected] http://lists.nongnu.org/mailman/listinfo/quilt-dev
