diff --git a/zephyr-env.sh b/zephyr-env.sh index f5b90d2f80..f6c7f23c5a 100644 --- a/zephyr-env.sh +++ b/zephyr-env.sh @@ -12,7 +12,7 @@ # # Note: The version of zsh need to be 5.0.6 or above. Any versions below # 5.0.6 maybe encoutner errors when sourcing this script. -if [ -n "$ZSH_VERSION" ]; then +if [ -n "${ZSH_VERSION:-}" ]; then DIR="${(%):-%N}" if [ $options[posixargzero] != "on" ]; then setopt posixargzero