diff options
author | Konstantin Osipov <kostja@sun.com> | 2009-12-01 01:33:22 +0300 |
---|---|---|
committer | Konstantin Osipov <kostja@sun.com> | 2009-12-01 01:33:22 +0300 |
commit | e23046d1bcaf54838167dd6bd3d8c6900e24b2ef (patch) | |
tree | ba3438eef550d9cf10d121bad3981f18566659d4 /sql/log_event.cc | |
parent | cf45b61a6a611415161e6176b8c8ae85a51e9349 (diff) | |
download | mariadb-git-e23046d1bcaf54838167dd6bd3d8c6900e24b2ef.tar.gz |
Backport of:
------------------------------------------------------------
revno: 2630.4.17
committer: Dmitry Lenev <dlenev@mysql.com>
branch nick: mysql-6.0-3726-w2
timestamp: Thu 2008-05-29 16:52:56 +0400
message:
WL#3726 "DDL locking for all metadata objects".
After review fixes in progress.
"The great correction of names".
Renamed MDL_LOCK and MDL_LOCK_DATA classes to make usage of
these names in metadata locking subsystem consistent with
other parts of server (i.e. thr_lock.cc). Now we MDL_LOCK_DATA
corresponds to request for a lock and MDL_LOCK to the lock
itself. Adjusted code in MDL subsystem and other places
using these classes accordingly.
Did similar thing for GLOBAL_MDL_LOCK_DATA class and also
changed name of its members to correspond to names of
MDL_LOCK_DATA members.
Finally got rid of usage of one letter variables in MDL
code since it makes code harder to search in (according
to reviewer).
Diffstat (limited to 'sql/log_event.cc')
-rw-r--r-- | sql/log_event.cc | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/sql/log_event.cc b/sql/log_event.cc index fd0e20d690d..92de9933181 100644 --- a/sql/log_event.cc +++ b/sql/log_event.cc @@ -8058,7 +8058,7 @@ int Table_map_log_event::do_apply_event(Relay_log_info const *rli) { RPL_TABLE_LIST *table_list; char *db_mem, *tname_mem, *mdlkey; - MDL_LOCK *mdl_lock; + MDL_LOCK_DATA *mdl_lock_data; size_t dummy_len; void *memory; DBUG_ENTER("Table_map_log_event::do_apply_event(Relay_log_info*)"); @@ -8073,7 +8073,7 @@ int Table_map_log_event::do_apply_event(Relay_log_info const *rli) &table_list, (uint) sizeof(RPL_TABLE_LIST), &db_mem, (uint) NAME_LEN + 1, &tname_mem, (uint) NAME_LEN + 1, - &mdl_lock, sizeof(MDL_LOCK), + &mdl_lock_data, sizeof(MDL_LOCK_DATA), &mdlkey, MAX_DBKEY_LENGTH, NullS))) DBUG_RETURN(HA_ERR_OUT_OF_MEM); @@ -8087,8 +8087,9 @@ int Table_map_log_event::do_apply_event(Relay_log_info const *rli) table_list->updating= 1; strmov(table_list->db, rpl_filter->get_rewrite_db(m_dbnam, &dummy_len)); strmov(table_list->table_name, m_tblnam); - mdl_init_lock(mdl_lock, mdlkey, 0, table_list->db, table_list->table_name); - table_list->mdl_lock= mdl_lock; + mdl_init_lock(mdl_lock_data, mdlkey, 0, table_list->db, + table_list->table_name); + table_list->mdl_lock_data= mdl_lock_data; int error= 0; |