]> git.ipfire.org Git - thirdparty/dracut-ng.git/commitdiff
fix(dracut-catimages.sh): do not call shift for options without arguments
authorAntonio Alvarez Feijoo <antonio.feijoo@suse.com>
Thu, 12 Mar 2026 12:55:46 +0000 (13:55 +0100)
committerNeal Gompa (ニール・ゴンパ) <ngompa13@gmail.com>
Mon, 27 Apr 2026 14:58:52 +0000 (10:58 -0400)
`--nooverlay` and `--noimagedir` do not expect any arguments, so calling shift
after processing them has unintended effects.

dracut-catimages.sh

index f28f35ba69622a337b9bbd9c1d04f512adadc0e3..bfcf00e8b6fc7217f9d6ee478f98b749556b86ce 100755 (executable)
@@ -60,11 +60,9 @@ while (($# > 0)); do
             ;;
         --nooverlay)
             no_overlay=yes
-            shift
             ;;
         --noimagedir)
             no_imagedir=yes
-            shift
             ;;
         -h | --help)
             usage