diff --git a/client/mysql.cc b/client/mysql.cc index 715d74f18b2..60f724863ff 100644 --- a/client/mysql.cc +++ b/client/mysql.cc @@ -2671,7 +2671,7 @@ You can turn off this feature to get a quicker startup with -A\n\n"); mysql_free_result(fields); break; } - field_names[i][num_fields*2]= '\0'; + field_names[i][num_fields*2]= NULL; j=0; while ((sql_field=mysql_fetch_field(fields))) { diff --git a/client/mysqlcheck.c b/client/mysqlcheck.c index 7822460e341..c7372a39299 100644 --- a/client/mysqlcheck.c +++ b/client/mysqlcheck.c @@ -440,6 +440,7 @@ static int process_all_databases() if (process_one_db(row[0])) result = 1; } + mysql_free_result(tableres); return result; } /* process_all_databases */ @@ -910,10 +911,10 @@ static int dbConnect(char *host, char *user, char *passwd) opt_ssl_mode == SSL_MODE_REQUIRED))) { DBerror(&mysql_connection, "when trying to connect"); - return 1; + DBUG_RETURN(1); } mysql_connection.reconnect= 1; - return 0; + DBUG_RETURN(0); } /* dbConnect */ diff --git a/mysql-test/mysql-test-run.pl b/mysql-test/mysql-test-run.pl index 99d3203fb51..8086c641d11 100755 --- a/mysql-test/mysql-test-run.pl +++ b/mysql-test/mysql-test-run.pl @@ -100,6 +100,8 @@ use mtr_results; use IO::Socket::INET; use IO::Select; +push @INC, "."; + require "lib/mtr_process.pl"; require "lib/mtr_io.pl"; require "lib/mtr_gcov.pl"; diff --git a/sql/gen_lex_hash.cc b/sql/gen_lex_hash.cc index fc6d0938d13..569a2a1a4d0 100644 --- a/sql/gen_lex_hash.cc +++ b/sql/gen_lex_hash.cc @@ -311,6 +311,7 @@ void print_find_structs() set_links(root_by_len,max_len); print_hash_map("sql_functions_map"); + free(hash_map); hash_map= 0; size_hash_map= 0; @@ -319,6 +320,10 @@ void print_find_structs() add_structs_to_map(root_by_len2,max_len2); set_links(root_by_len2,max_len2); print_hash_map("symbols_map"); + + free(hash_map); + hash_map= 0; + size_hash_map= 0; }