Skip to content

Commit

Permalink
Fixes support package version comparison to use correct argument (#1625)
Browse files Browse the repository at this point in the history
  • Loading branch information
Stringy authored Apr 4, 2024
1 parent 066b614 commit 641a536
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions kernel-modules/support-packages/utils.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,13 @@ _check_min_version() {
exit 1
fi

if [[ ! "$1" =~ $version_re ]]; then
if [[ ! "$2" =~ $version_re ]]; then
echo >&2 "Error: Invalid version number format '$2'"
exit 1
fi

IFS='.' read -ra version <<< "${1%-*}"
IFS='.' read -ra min_version <<< "${1%-*}"
IFS='.' read -ra min_version <<< "${2%-*}"

for ((i = 0; i < ${#min_version[@]}; i++)); do
if ((version[i] < min_version[i])); then
Expand Down

0 comments on commit 641a536

Please sign in to comment.