summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergei Golubchik <serg@mariadb.org>2019-03-05 00:32:04 +0100
committerSergei Golubchik <serg@mariadb.org>2019-03-06 15:28:27 +0100
commit57dd892ce8dc93bcd7eee953e01ebe8ed7e414c8 (patch)
tree01723d74f93745f039ecdfb06d46c1fe6495e1a4
parent2f742b571f93e8c4a87145ee80757192f14a019b (diff)
downloadmariadb-git-57dd892ce8dc93bcd7eee953e01ebe8ed7e414c8.tar.gz
fix memory leaks in mysql_client_test
This fixes main.mysql_client_test, main.mysql_client_test_comp, main.mysql_client_test_nonblock failures in ASAN_OPTIONS="abort_on_error=1" runs
-rw-r--r--tests/mysql_client_test.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/mysql_client_test.c b/tests/mysql_client_test.c
index d12ca2ab96a..9c64342954a 100644
--- a/tests/mysql_client_test.c
+++ b/tests/mysql_client_test.c
@@ -18426,6 +18426,7 @@ static void test_bug42373()
DIE_UNLESS(rc == 1);
mysql_stmt_close(stmt);
+ mysql_close(&con);
/* Now try with a multi-statement. */
DIE_UNLESS(mysql_client_init(&con));
@@ -18888,8 +18889,6 @@ static void test_progress_reporting()
conn= client_connect(CLIENT_PROGRESS_OBSOLETE, MYSQL_PROTOCOL_TCP, 0);
- if (!(conn->server_capabilities & CLIENT_PROGRESS_OBSOLETE))
- return;
DIE_UNLESS(conn->client_flag & CLIENT_PROGRESS_OBSOLETE);
mysql_options(conn, MYSQL_PROGRESS_CALLBACK, (void*) report_progress);
@@ -19739,6 +19738,7 @@ static void test_bulk_delete()
DIE_IF(atoi(row[0]) != 3);
}
DIE_IF(i != 1);
+ mysql_free_result(result);
rc= mysql_query(mysql, "DROP TABLE t1");
myquery(rc);