diff options
author | Marko Mäkelä <marko.makela@mariadb.com> | 2019-02-02 13:00:15 +0200 |
---|---|---|
committer | Marko Mäkelä <marko.makela@mariadb.com> | 2019-02-02 13:00:15 +0200 |
commit | 213ece2f2e8c23ee0e727cc02dcecfae6f510ca2 (patch) | |
tree | 5ce93ecb5caa9a58ebc08f8cd3e94c59d7219377 /client | |
parent | c1e1764fc4b913ee688b383aac2698b83661d64c (diff) | |
parent | d9d83f1d92b696ef56f4944df036b8a78364ebb4 (diff) | |
download | mariadb-git-213ece2f2e8c23ee0e727cc02dcecfae6f510ca2.tar.gz |
Merge 10.1 into 10.1
This is joint work with Oleksandr Byelkin.
Diffstat (limited to 'client')
-rw-r--r-- | client/mysqltest.cc | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/client/mysqltest.cc b/client/mysqltest.cc index 250f73fe3fc..b2a63287709 100644 --- a/client/mysqltest.cc +++ b/client/mysqltest.cc @@ -6075,7 +6075,6 @@ void do_connect(struct st_command *command) #endif if (opt_compress || con_compress) mysql_options(con_slot->mysql, MYSQL_OPT_COMPRESS, NullS); - mysql_options(con_slot->mysql, MYSQL_OPT_LOCAL_INFILE, 0); mysql_options(con_slot->mysql, MYSQL_SET_CHARSET_NAME, charset_info->csname); if (opt_charsets_dir) @@ -6175,6 +6174,11 @@ void do_connect(struct st_command *command) if (con_slot == next_con) next_con++; /* if we used the next_con slot, advance the pointer */ } + else // Failed to connect. Free the memory. + { + mysql_close(con_slot->mysql); + con_slot->mysql= NULL; + } dynstr_free(&ds_connection_name); dynstr_free(&ds_host); @@ -9175,7 +9179,6 @@ int main(int argc, char **argv) (void *) &opt_connect_timeout); if (opt_compress) mysql_options(con->mysql,MYSQL_OPT_COMPRESS,NullS); - mysql_options(con->mysql, MYSQL_OPT_LOCAL_INFILE, 0); mysql_options(con->mysql, MYSQL_SET_CHARSET_NAME, charset_info->csname); if (opt_charsets_dir) |