diff options
author | Michael Widenius <monty@mariadb.org> | 2018-07-29 10:56:11 +0300 |
---|---|---|
committer | Michael Widenius <monty@mariadb.org> | 2018-07-29 10:56:11 +0300 |
commit | 0c745c743c65ceb6533babdf21556b633e81566c (patch) | |
tree | 5e23f8cbbab830786b1eaeb6190a639d5b8d7414 /extra/perror.c | |
parent | 255328d3931e8526c4248ec2af1f554911376c1b (diff) | |
download | mariadb-git-0c745c743c65ceb6533babdf21556b633e81566c.tar.gz |
Don't give warnings from perror or resolveip with safemalloc
- Added my_end(0) before exit
- Fixed typo in mysql_install_db
Diffstat (limited to 'extra/perror.c')
-rw-r--r-- | extra/perror.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/extra/perror.c b/extra/perror.c index 3bc5120db48..bd62401c8b2 100644 --- a/extra/perror.c +++ b/extra/perror.c @@ -105,11 +105,13 @@ get_one_option(int optid, const struct my_option *opt __attribute__((unused)), break; case 'V': print_version(); + my_end(0); exit(0); break; case 'I': case '?': usage(); + my_end(0); exit(0); break; } @@ -122,7 +124,10 @@ static int get_options(int *argc,char ***argv) int ho_error; if ((ho_error=handle_options(argc, argv, my_long_options, get_one_option))) + { + my_end(0); exit(ho_error); + } if (!*argc && !print_all_codes) { @@ -260,7 +265,10 @@ int main(int argc,char *argv[]) MY_INIT(argv[0]); if (get_options(&argc,&argv)) + { + my_end(0); exit(1); + } my_handler_error_register(); |