diff options
author | monty@donna.mysql.com <> | 2000-10-23 15:35:42 +0300 |
---|---|---|
committer | monty@donna.mysql.com <> | 2000-10-23 15:35:42 +0300 |
commit | 8dabd3b053f11f5f03744019a888b860d725a565 (patch) | |
tree | 20b25b09438bf3aad77ad7810faab9651daf310f /sql/sql_insert.cc | |
parent | e0b30726001e3fe43e6f34194eed1c8fc3979718 (diff) | |
download | mariadb-git-8dabd3b053f11f5f03744019a888b860d725a565.tar.gz |
Fix of automatic repair
Diffstat (limited to 'sql/sql_insert.cc')
-rw-r--r-- | sql/sql_insert.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sql/sql_insert.cc b/sql/sql_insert.cc index b32e5393404..9fc47cd4dfc 100644 --- a/sql/sql_insert.cc +++ b/sql/sql_insert.cc @@ -567,6 +567,9 @@ static TABLE *delayed_get_table(THD *thd,TABLE_LIST *table_list) pthread_mutex_unlock(&LOCK_delayed_create); DBUG_RETURN(0); } + pthread_mutex_lock(&LOCK_thread_count); + thread_count++; + pthread_mutex_unlock(&LOCK_thread_count); if (!(tmp->thd.db=my_strdup(table_list->db,MYF(MY_WME))) || !(tmp->thd.query=my_strdup(table_list->real_name,MYF(MY_FAE)))) { @@ -578,9 +581,6 @@ static TABLE *delayed_get_table(THD *thd,TABLE_LIST *table_list) } tmp->table_list=table_list; // Needed to open table tmp->lock(); - pthread_mutex_lock(&LOCK_thread_count); - thread_count++; - pthread_mutex_unlock(&LOCK_thread_count); pthread_mutex_lock(&tmp->mutex); if ((error=pthread_create(&tmp->thd.real_id,&connection_attrib, handle_delayed_insert,(void*) tmp))) |