From 7b9586ad300e0543b04910541d87174bb38b45dc Mon Sep 17 00:00:00 2001 From: oddlama Date: Wed, 28 Sep 2022 17:55:13 +0200 Subject: [PATCH] fix: checkfile set even if tuple is not a expression (fixes #51) --- scripts/utils.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/scripts/utils.sh b/scripts/utils.sh index cd835cf..e52797c 100644 --- a/scripts/utils.sh +++ b/scripts/utils.sh @@ -377,7 +377,9 @@ function check_wanted_programs() { local checkfile for tuple in "$@"; do program="${tuple%%=*}" - checkfile="${tuple##*=}" + checkfile="" + [[ "$tuple" == *=* ]] \ + checkfile="${tuple##*=}" if ! has_program "${program#"?"}" "$checkfile"; then if [[ "$program" == "?"* ]]; then missing_wanted+=("${program#"?"}")