From 0cdf39d601750d25e7db39d32a6e654026f001df Mon Sep 17 00:00:00 2001 From: maximilian attems Date: Mon, 30 Mar 2009 18:29:05 +0200 Subject: update-initramfs: Fix error message on wrong -k version argument update-initramfs -k $(uname -a) -t -u You must specify at least one of -c, -u, or -d. [..] which is wrong as -u was reported. Reported-by: Michael Prokop --- update-initramfs | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'update-initramfs') diff --git a/update-initramfs b/update-initramfs index ad65ef2..be0616a 100755 --- a/update-initramfs +++ b/update-initramfs @@ -504,6 +504,13 @@ while getopts "k:cudyvtb:h?" flag; do esac done +shift $((${OPTIND} - 1)) + +if [ $# -ne 0 ]; then + echo "Invalid argument for option -k." + usage +fi + # Validate arguments if [ -z "${mode}" ]; then usage "You must specify at least one of -c, -u, or -d." -- cgit v1.2.3