summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorShunpoco <tkngsnsk313320@gmail.com>2022-04-11 22:43:02 +0900
committerDaniel Black <daniel@mariadb.org>2022-04-12 08:17:32 +1000
commit767d8d8335f9d45efb86c77a9efa0b42aff1eb27 (patch)
treea2c0c357244f694952fa6e757476ba56f391a70a
parent833f4486cf7c9858e1f6d2e2deeded6d43fd4e21 (diff)
downloadmariadb-git-767d8d8335f9d45efb86c77a9efa0b42aff1eb27.tar.gz
MDEV-27448 MTR returns success (zero) upon invalid option
I change from `exit;` to `exit(1);` on a function `usage()`. When we try to run mtr with a wrong option, a function `usage()` is called with the wrong option as its argument. In this case, because the function call `exit` in a first if statement, we get exit status 0.
-rwxr-xr-xmysql-test/mysql-test-run.pl2
1 files changed, 1 insertions, 1 deletions
diff --git a/mysql-test/mysql-test-run.pl b/mysql-test/mysql-test-run.pl
index bbe5df4c57a..29a706a311a 100755
--- a/mysql-test/mysql-test-run.pl
+++ b/mysql-test/mysql-test-run.pl
@@ -5726,7 +5726,7 @@ sub usage ($) {
{
print STDERR "$message\n";
print STDERR "For full list of options, use $0 --help\n";
- exit;
+ exit(1);
}
local $"= ','; # for @DEFAULT_SUITES below