From df09d5e724af93fea096fd841fad9e93d2615ad5 Mon Sep 17 00:00:00 2001 From: Oleksandr Byelkin Date: Mon, 15 Aug 2016 16:28:19 +0200 Subject: MDEV-10559: main.mysql_client_test_nonblock crashes in buildbot on 10.0 Fix tests which possibly fail connects in non_blocking mode. --- tests/mysql_client_test.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'tests') diff --git a/tests/mysql_client_test.c b/tests/mysql_client_test.c index fcc89482f4e..640ba298556 100644 --- a/tests/mysql_client_test.c +++ b/tests/mysql_client_test.c @@ -18440,9 +18440,10 @@ static void test_bug58036() /* Part1: try to connect with ucs2 client character set */ conn= mysql_client_init(NULL); mysql_options(conn, MYSQL_SET_CHARSET_NAME, "ucs2"); + if (mysql_real_connect(conn, opt_host, opt_user, opt_password, opt_db ? opt_db : "test", - opt_port, opt_unix_socket, 0)) + opt_port, opt_unix_socket, CLIENT_REMEMBER_OPTIONS)) { if (!opt_silent) printf("mysql_real_connect() succeeded (failure expected)\n"); @@ -18468,7 +18469,7 @@ static void test_bug58036() mysql_options(conn, MYSQL_SET_CHARSET_NAME, "latin1"); if (!mysql_real_connect(conn, opt_host, opt_user, opt_password, opt_db ? opt_db : "test", - opt_port, opt_unix_socket, 0)) + opt_port, opt_unix_socket, CLIENT_REMEMBER_OPTIONS)) { if (!opt_silent) printf("mysql_real_connect() failed: %s (%d)\n", @@ -18490,7 +18491,6 @@ static void test_bug58036() printf("Got mysql_change_user() error (expected): %s (%d)\n", mysql_error(conn), mysql_errno(conn)); mysql_close(conn); - DBUG_VOID_RETURN; } @@ -19344,8 +19344,9 @@ static void test_big_packet() if (!(mysql_real_connect(mysql_local, opt_host, opt_user, opt_password, current_db, opt_port, - opt_unix_socket, 0))) + opt_unix_socket, CLIENT_REMEMBER_OPTIONS))) { + mysql_close(mysql_local); fprintf(stderr, "\n connection failed(%s)", mysql_error(mysql_local)); exit(1); } -- cgit v1.2.1 From 05f61ba46046ca835071a73b9255e787dcce9255 Mon Sep 17 00:00:00 2001 From: Oleksandr Byelkin Date: Tue, 16 Aug 2016 21:23:57 +0200 Subject: MDEV-10559: main.mysql_client_test_nonblock crashes in buildbot on 10.0 fix for async operations --- tests/mysql_client_test.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'tests') diff --git a/tests/mysql_client_test.c b/tests/mysql_client_test.c index 640ba298556..2acec60166e 100644 --- a/tests/mysql_client_test.c +++ b/tests/mysql_client_test.c @@ -18443,7 +18443,7 @@ static void test_bug58036() if (mysql_real_connect(conn, opt_host, opt_user, opt_password, opt_db ? opt_db : "test", - opt_port, opt_unix_socket, CLIENT_REMEMBER_OPTIONS)) + opt_port, opt_unix_socket, 0)) { if (!opt_silent) printf("mysql_real_connect() succeeded (failure expected)\n"); @@ -18469,7 +18469,7 @@ static void test_bug58036() mysql_options(conn, MYSQL_SET_CHARSET_NAME, "latin1"); if (!mysql_real_connect(conn, opt_host, opt_user, opt_password, opt_db ? opt_db : "test", - opt_port, opt_unix_socket, CLIENT_REMEMBER_OPTIONS)) + opt_port, opt_unix_socket, 0)) { if (!opt_silent) printf("mysql_real_connect() failed: %s (%d)\n", @@ -19344,7 +19344,7 @@ static void test_big_packet() if (!(mysql_real_connect(mysql_local, opt_host, opt_user, opt_password, current_db, opt_port, - opt_unix_socket, CLIENT_REMEMBER_OPTIONS))) + opt_unix_socket, 0))) { mysql_close(mysql_local); fprintf(stderr, "\n connection failed(%s)", mysql_error(mysql_local)); -- cgit v1.2.1