@@ -982,7 +982,27 @@ static int test_conc_114(MYSQL *mysql)
982982 return OK ;
983983}
984984
985+ /* run with valgrind */
986+ static int test_conc117 (MYSQL * mysql )
987+ {
988+ MYSQL * my = mysql_init (NULL );
989+ FAIL_IF (!mysql_real_connect (my , hostname , username , password , schema ,
990+ port , socketname , 0 ), mysql_error (my ));
991+
992+ mysql_kill (my , mysql_thread_id (my ));
993+ sleep (5 );
994+
995+ strcpy (my -> host , "A" );
996+ my -> reconnect = 1 ;
997+
998+ mysql_query (my , "SET @a:=1" );
999+ mysql_close (my );
1000+
1001+ return OK ;
1002+ }
1003+
9851004struct my_tests_st my_tests [] = {
1005+ {"test_conc117" , test_conc117 , TEST_CONNECTION_DEFAULT , 0 , NULL , NULL },
9861006 {"test_conc_114" , test_conc_114 , TEST_CONNECTION_DEFAULT , 0 , NULL , NULL },
9871007 {"test_connect_attrs" , test_connect_attrs , TEST_CONNECTION_DEFAULT , 0 , NULL , NULL },
9881008 {"test_conc49" , test_conc49 , TEST_CONNECTION_DEFAULT , 0 , NULL , NULL },
@@ -1002,7 +1022,7 @@ struct my_tests_st my_tests[] = {
10021022 {"test_ldi_path" , test_ldi_path , TEST_CONNECTION_NEW , 0 , NULL , NULL },
10031023#ifdef _WIN32
10041024 {"test_conc44" , test_conc44 , TEST_CONNECTION_NEW , 0 , NULL , NULL },
1005- #endif
1025+ #endif
10061026 {NULL , NULL , 0 , 0 , NULL , 0 }
10071027};
10081028
0 commit comments