Skip to content

Commit

Permalink
Fix syntax errors in Kissat checking script
Browse files Browse the repository at this point in the history
In bash, `return` can only be used within a function. Use `exit`
instead.
  • Loading branch information
tautschnig committed Sep 15, 2023
1 parent 04c7451 commit e010aa7
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions scripts/check_kissat_version.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,16 @@ source "${KANI_DIR}/kani-dependencies"

if [ -z "${KISSAT_VERSION:-}" ]; then
echo "$0: ERROR: KISSAT_VERSION is not set"
return 1
exit 1
fi
cmd="kissat --version"
if kissat_version=$($cmd); then
# Perform a lexicographic comparison of the version
if [[ $kissat_version < $KISSAT_VERSION ]]; then
echo "ERROR: Kissat version is $kissat_version. Expected at least $KISSAT_VERSION."
return 1
exit 1
fi
else
echo "ERROR: Couldn't run command '$cmd'"
return 1
exit 1
fi

0 comments on commit e010aa7

Please sign in to comment.