Fix threadpool memory leak and connect2 test

This commit is contained in:
Vladislav Vaintroub 2016-03-09 10:19:09 +01:00
commit 351026ca53
5 changed files with 11 additions and 2 deletions

View file

@ -663,6 +663,7 @@ void tp_add_connection(CONNECT *connect)
{
connection_t *con;
con= (connection_t *)malloc(sizeof(connection_t));
DBUG_EXECUTE_IF("simulate_failed_connection_1", free(con);con= 0; );
if (!con)
{
tp_log_warning("Allocation failed", "tp_add_connection");