From: Francis Dupont Date: Wed, 9 Sep 2020 13:39:04 +0000 (+0200) Subject: [#828] Fixed shellcheck X-Git-Tag: Kea-1.9.0~157 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7f7865cb2a15d62cccb73ece0239511b7bb49c4c;p=thirdparty%2Fkea.git [#828] Fixed shellcheck --- diff --git a/src/bin/admin/admin-utils.sh b/src/bin/admin/admin-utils.sh index a698640b22..0041caa1ec 100644 --- a/src/bin/admin/admin-utils.sh +++ b/src/bin/admin/admin-utils.sh @@ -53,13 +53,14 @@ mysql_version() { } checked_mysql_version() { - mysql_version + mysql_execute "SELECT CONCAT_WS('.', version, minor) FROM schema_version" "$@" retcode=$? if [ $retcode -ne 0 ] then printf "Failed to get schema version, mysql status %s\n" "${retcode}" exit 1 fi + return $retcode } # Submits given SQL text to PostgreSQL @@ -116,13 +117,14 @@ pgsql_version() { } checked_pgsql_version() { - pgsql_version + pgsql_execute "SELECT version || '.' || minor FROM schema_version" "$@" retcode=$? if [ $retcode -ne 0 ] then printf "Failed to get schema version, pgsql status %s\n" "${retcode}" exit 1 fi + return $retcode } cql_execute() {