MXS-3408 Fix leak in qc_mysqlembedded properly
The actual cause was a missing cleanup call.
This commit is contained in:
		@ -1960,6 +1960,7 @@ static void parsing_info_done(void* ptr)
 | 
			
		||||
            {
 | 
			
		||||
                thd = (THD*) mysql->thd;
 | 
			
		||||
                thd->end_statement();
 | 
			
		||||
                thd->cleanup_after_query();
 | 
			
		||||
                (*mysql->methods->free_embedded_thd)(mysql);
 | 
			
		||||
                mysql->thd = NULL;
 | 
			
		||||
            }
 | 
			
		||||
 | 
			
		||||
@ -700,9 +700,7 @@ create table t2 (a int, b int, primary key(a));
 | 
			
		||||
 | 
			
		||||
explain select * from t1;
 | 
			
		||||
show status like '%cost%';
 | 
			
		||||
#MXS The following line causes a leak in qc_mysqlembedded that causes ASAN to
 | 
			
		||||
#MXS complain. Easiest to solve by commenting out.
 | 
			
		||||
#select 'The cost of accessing t1 (dont care if it changes' '^';
 | 
			
		||||
select 'The cost of accessing t1 (dont care if it changes' '^';
 | 
			
		||||
 | 
			
		||||
select 'vv: Following query must use ALL(t1), eq_ref(A), eq_ref(B): vv' Z;
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
		Reference in New Issue
	
	Block a user