Fix memory leaks found when valgrinding mysql_client_test

Remove one warning
parent e193c7bf
...@@ -14480,6 +14480,7 @@ static void test_bug11718() ...@@ -14480,6 +14480,7 @@ static void test_bug11718()
printf("return type: %s", (res->fields[0].type == MYSQL_TYPE_DATE)?"DATE": printf("return type: %s", (res->fields[0].type == MYSQL_TYPE_DATE)?"DATE":
"not DATE"); "not DATE");
DIE_UNLESS(res->fields[0].type == MYSQL_TYPE_DATE); DIE_UNLESS(res->fields[0].type == MYSQL_TYPE_DATE);
mysql_free_result(res);
rc= mysql_query(mysql, "drop table t1, t2"); rc= mysql_query(mysql, "drop table t1, t2");
myquery(rc); myquery(rc);
} }
...@@ -14928,6 +14929,8 @@ static void test_bug15613() ...@@ -14928,6 +14929,8 @@ static void test_bug15613()
DIE_UNLESS(field[4].length == 255); DIE_UNLESS(field[4].length == 255);
DIE_UNLESS(field[5].length == 255); DIE_UNLESS(field[5].length == 255);
DIE_UNLESS(field[6].length == 255); DIE_UNLESS(field[6].length == 255);
mysql_free_result(metadata);
mysql_stmt_free_result(stmt);
/* III. Cleanup */ /* III. Cleanup */
rc= mysql_query(mysql, "drop table t1"); rc= mysql_query(mysql, "drop table t1");
...@@ -15104,6 +15107,9 @@ static void test_bug14169() ...@@ -15104,6 +15107,9 @@ static void test_bug14169()
if (!opt_silent) if (!opt_silent)
printf("GROUP_CONCAT() result type %i", field[1].type); printf("GROUP_CONCAT() result type %i", field[1].type);
DIE_UNLESS(field[1].type == MYSQL_TYPE_BLOB); DIE_UNLESS(field[1].type == MYSQL_TYPE_BLOB);
mysql_free_result(res);
mysql_stmt_free_result(stmt);
mysql_stmt_close(stmt);
rc= mysql_query(mysql, "drop table t1"); rc= mysql_query(mysql, "drop table t1");
myquery(rc); myquery(rc);
...@@ -15168,7 +15174,7 @@ static void test_bug15752() ...@@ -15168,7 +15174,7 @@ static void test_bug15752()
MYSQL mysql_local; MYSQL mysql_local;
int rc, i; int rc, i;
const int ITERATION_COUNT= 100; const int ITERATION_COUNT= 100;
char *query= "CALL p1()"; const char *query= "CALL p1()";
myheader("test_bug15752"); myheader("test_bug15752");
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment