From 1ab8e8620a387e38e0b075d6f3aeebdc4347208d Mon Sep 17 00:00:00 2001 From: stormdragon2976 Date: Tue, 6 Dec 2022 01:15:23 -0500 Subject: [PATCH] Fixed a bug in array size check. --- speech/set-voice.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/speech/set-voice.sh b/speech/set-voice.sh index f6f9cd6..9043f46 100755 --- a/speech/set-voice.sh +++ b/speech/set-voice.sh @@ -194,7 +194,7 @@ for x in "${voiceListFullName[@]}" ; do done oldVoice="$($grep -P '"DefaultTokenId"="HKEY_LOCAL_MACHINE\\\\(SOFTWARE|Software)\\\\(Wow6432Node\\\\|)Microsoft\\\\Speech\\\\Voices\\\\Token(Enum|)s\\\\[^"]+"' "${WINEPREFIX}/user.reg" | $sed -E -e 's/"DefaultTokenId"="([^"]+)"/\1/g')" exit=1 -if [[ "${voiceList[@]}" -eq 0 ]]; then +if [[ "${#voiceList[@]}" -eq 0 ]]; then dialog --msgbox "No voices found." -1 -1 exit 1 fi