1
0
mirror of https://github.com/MariaDB/server.git synced 2025-12-24 11:21:21 +03:00
- Don't call update_virtual_fields() if table->vfield is not set
- Don't prealloc memory for in open_tables() as this is very seldom used.


sql/records.cc:
  Don't call update_virtual_fields() if table->vfield is not set
sql/sql_base.cc:
  Don't prealloc memory for in open_tables() as this is very seldom used.
  Don't call update_virtual_fields() if table->vfield is not set
sql/sql_delete.cc:
  Don't call update_virtual_fields() if table->vfield is not set
sql/sql_handler.cc:
  Don't call update_virtual_fields() if table->vfield is not set
sql/sql_join_cache.cc:
  Don't call update_virtual_fields() if table->vfield is not set
  Move some frequent values to local variables
sql/sql_table.cc:
  Don't call update_virtual_fields() if table->vfield is not set
sql/sql_update.cc:
  Don't call update_virtual_fields() if table->vfield is not set
sql/table.cc:
  Assert if update_virtual_fields is called with wrong parameters
This commit is contained in:
Michael Widenius
2012-03-23 18:22:39 +02:00
parent 8e825a2249
commit c36bdf1c88
8 changed files with 29 additions and 25 deletions

View File

@@ -8078,7 +8078,8 @@ copy_data_between_tables(THD *thd, TABLE *from,TABLE *to,
error= 1;
break;
}
update_virtual_fields(thd, from);
if (from->vfield)
update_virtual_fields(thd, from);
thd->row_count++;
if (++thd->progress.counter >= time_to_report_progress)
{
@@ -8106,7 +8107,8 @@ copy_data_between_tables(THD *thd, TABLE *from,TABLE *to,
copy_ptr->do_copy(copy_ptr);
}
prev_insert_id= to->file->next_insert_id;
update_virtual_fields(thd, to, TRUE);
if (to->vfield)
update_virtual_fields(thd, to, TRUE);
if (thd->is_error())
{
error= 1;