From 7b89b9f5108c80f4f270da922d7e6c182a663719 Mon Sep 17 00:00:00 2001 From: Vladislav Vaintroub Date: Fri, 19 Aug 2016 15:27:37 +0000 Subject: MDEV-9293 Connector/C integration --- tests/mysql_client_fw.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'tests/mysql_client_fw.c') 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 #include #include +#include #include #include @@ -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)); -- cgit v1.2.1