diff options
author | Vladislav Vaintroub <wlad@mariadb.com> | 2016-08-19 15:27:37 +0000 |
---|---|---|
committer | Vladislav Vaintroub <wlad@mariadb.com> | 2016-08-19 15:27:37 +0000 |
commit | 7b89b9f5108c80f4f270da922d7e6c182a663719 (patch) | |
tree | 858a3873942f07610fb26685781e8bdbd3ab2c7f /tests/mysql_client_fw.c | |
parent | daff133ddf9a9d120050703c0b5753979c6190e0 (diff) | |
download | mariadb-git-7b89b9f5108c80f4f270da922d7e6c182a663719.tar.gz |
MDEV-9293 Connector/C integration
Diffstat (limited to 'tests/mysql_client_fw.c')
-rw-r--r-- | tests/mysql_client_fw.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/tests/mysql_client_fw.c b/tests/mysql_client_fw.c index b7211989f1f..50ecf6c0860 100644 --- a/tests/mysql_client_fw.c +++ b/tests/mysql_client_fw.c @@ -21,6 +21,7 @@ #include <my_getopt.h> #include <m_string.h> #include <mysqld_error.h> +#include <mysql_version.h> #include <sql_common.h> #include <mysql/client_plugin.h> @@ -363,7 +364,7 @@ static MYSQL* client_connect(ulong flag, uint protocol, my_bool auto_reconnect) fprintf(stdout, "\n Check the connection options using --help or -?\n"); exit(1); } - mysql->reconnect= auto_reconnect; + mysql_options(mysql, MYSQL_OPT_RECONNECT, &auto_reconnect); if (!opt_silent) fprintf(stdout, "OK"); @@ -1145,7 +1146,7 @@ static my_bool thread_query(const char *query) { MYSQL *l_mysql; my_bool error; - + my_bool reconnect= 1; error= 0; if (!opt_silent) fprintf(stdout, "\n in thread_query(%s)", query); @@ -1162,7 +1163,7 @@ static my_bool thread_query(const char *query) error= 1; goto end; } - l_mysql->reconnect= 1; + mysql_options(l_mysql, MYSQL_OPT_RECONNECT, &reconnect); if (mysql_query(l_mysql, query)) { fprintf(stderr, "Query failed (%s)\n", mysql_error(l_mysql)); |