mirror of
https://github.com/MariaDB/server.git
synced 2026-05-04 14:15:33 +02:00
Merge 10.0-base -> 10.0
This commit is contained in:
commit
a9240dce9e
392 changed files with 192465 additions and 7638 deletions
|
|
@ -416,11 +416,13 @@ int emb_unbuffered_fetch(MYSQL *mysql, char **row)
|
|||
static void emb_free_embedded_thd(MYSQL *mysql)
|
||||
{
|
||||
THD *thd= (THD*)mysql->thd;
|
||||
mysql_mutex_lock(&LOCK_thread_count);
|
||||
thd->clear_data_list();
|
||||
thread_count--;
|
||||
thd->store_globals();
|
||||
thd->unlink();
|
||||
delete thd;
|
||||
mysql_mutex_unlock(&LOCK_thread_count);
|
||||
my_pthread_setspecific_ptr(THR_THD, 0);
|
||||
mysql->thd=0;
|
||||
}
|
||||
|
|
@ -687,8 +689,10 @@ void *create_embedded_thd(int client_flag)
|
|||
thd->data_tail= &thd->first_data;
|
||||
bzero((char*) &thd->net, sizeof(thd->net));
|
||||
|
||||
mysql_mutex_lock(&LOCK_thread_count);
|
||||
thread_count++;
|
||||
threads.append(thd);
|
||||
mysql_mutex_unlock(&LOCK_thread_count);
|
||||
thd->mysys_var= 0;
|
||||
return thd;
|
||||
err:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue