diff options
author | Andrei Pavel <andrei@isc.org> | 2022-01-23 13:52:45 +0100 |
---|---|---|
committer | Francis Dupont <fdupont@isc.org> | 2022-01-24 16:57:59 +0100 |
commit | 6d984769ad8029e7bcb36c36ec5ce54c55dcaf4a (patch) | |
tree | e5601e85dda933181a1a8cba5b4997f3273f7fea | |
parent | [#2225] Restored $# check (diff) | |
download | kea-6d984769ad8029e7bcb36c36ec5ce54c55dcaf4a.tar.xz kea-6d984769ad8029e7bcb36c36ec5ce54c55dcaf4a.zip |
[#2225] fix argument check in admin-utils.sh
-rw-r--r-- | src/bin/admin/admin-utils.sh | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/bin/admin/admin-utils.sh b/src/bin/admin/admin-utils.sh index c5e2b2d728..91b401286d 100644 --- a/src/bin/admin/admin-utils.sh +++ b/src/bin/admin/admin-utils.sh @@ -70,7 +70,7 @@ mysql_execute() { mysql_sanity_checks - if [ $# -gt 1 ]; then + if [ $# -gt 0 ]; then mysql -N -B --host="${db_host}" ${db_port_full_parameter-} \ --database="${db_name}" --user="${db_user}" \ --password="${db_password}" ${extra_arguments} \ @@ -94,7 +94,7 @@ mysql_execute_script() { mysql_sanity_checks - if [ $# -ge 1 ]; then + if [ $# -gt 0 ]; then mysql -N -B --host="${db_host}" ${db_port_full_parameter-} \ --database="${db_name}" --user="${db_user}" \ --password="${db_password}" ${extra_arguments} "${@}" < "${file}" |