]> git.ipfire.org Git - thirdparty/dracut-ng.git/commitdiff
test: ignore exit code of increment in qemu_add_drive
authorBenjamin Drung <benjamin.drung@canonical.com>
Wed, 12 Feb 2025 01:05:05 +0000 (02:05 +0100)
committerNeal Gompa (ニール・ゴンパ) <ngompa13@gmail.com>
Wed, 12 Feb 2025 13:50:58 +0000 (14:50 +0100)
Ignore error status code when incrementing from 0 to 1. See also
https://www.shellcheck.net/wiki/SC2219

Fixes: 1af00bf238c8 ("chore: resolve shellcheck for SC2219")
test/test-functions

index db02cea85dbcecd888ff6bda2641494f2c2bbc1c..c7c409fad018149336d0d3355ada61c750f8f8b2 100644 (file)
@@ -225,7 +225,7 @@ qemu_add_drive() {
         -device "scsi-hd,bus=scsi${index}.0,drive=drive-data${index},id=data${index},${bootindex:+bootindex=$bootindex,}serial=${name}" \
         ')'
 
-    [ $(("${1}++")) -ne 0 ]
+    : $(("${1}++"))
 }
 
 test_marker_reset() {