Skip to content

Commit

Permalink
Merge pull request #2461 from rbenv/openssl-version-check
Browse files Browse the repository at this point in the history
Avoid array subscript error when checking OpenSSL versions
  • Loading branch information
mislav authored Nov 5, 2024
2 parents 281e598 + bc88537 commit 1ab17da
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion bin/ruby-build
Original file line number Diff line number Diff line change
Expand Up @@ -1154,7 +1154,7 @@ needs_openssl() {
# shellcheck disable=SC2207
versions=( $(awk '{print $2}' <<<"$brew_installs" | sort_versions) )
local index="${#versions[@]}"
while [ $((index--)) -ge 0 ]; do
while [ $((--index)) -ge 0 ]; do
homebrew_version="$(normalize_semver "${versions[index]}")"
(( homebrew_version >= lower_bound && homebrew_version < upper_bound )) || continue
while read -r formula version prefix; do
Expand Down

0 comments on commit 1ab17da

Please sign in to comment.