diff options
author | Sergey Vojtovich <svoj@mariadb.org> | 2020-03-21 17:36:38 +0400 |
---|---|---|
committer | Sergey Vojtovich <svoj@mariadb.org> | 2020-03-21 17:36:38 +0400 |
commit | a39d92ca574e275acaf4240629d4bee5f9ece3f6 (patch) | |
tree | f67da71aeaef50ae0f9e673604a0a1f90b963b9c /sql/rpl_rli.cc | |
parent | 4d9977e5ff9843e132fda480536192caaf69aba2 (diff) | |
download | mariadb-git-a39d92ca574e275acaf4240629d4bee5f9ece3f6.tar.gz |
gtid_pos_table: my_atomic to std::atomic
Diffstat (limited to 'sql/rpl_rli.cc')
-rw-r--r-- | sql/rpl_rli.cc | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/sql/rpl_rli.cc b/sql/rpl_rli.cc index d645fea6968..18ee6a98ed0 100644 --- a/sql/rpl_rli.cc +++ b/sql/rpl_rli.cc @@ -2019,10 +2019,9 @@ find_gtid_slave_pos_tables(THD *thd) However we can add new entries, and warn about any tables that disappeared, but may still be visible to running SQL threads. */ - rpl_slave_state::gtid_pos_table *old_entry, *new_entry, **next_ptr_ptr; - - old_entry= (rpl_slave_state::gtid_pos_table *) - rpl_global_gtid_slave_state->gtid_pos_tables; + rpl_slave_state::gtid_pos_table *new_entry, **next_ptr_ptr; + auto old_entry= rpl_global_gtid_slave_state-> + gtid_pos_tables.load(std::memory_order_relaxed); while (old_entry) { new_entry= cb_data.table_list; @@ -2044,8 +2043,8 @@ find_gtid_slave_pos_tables(THD *thd) while (new_entry) { /* Check if we already have a table with this storage engine. */ - old_entry= (rpl_slave_state::gtid_pos_table *) - rpl_global_gtid_slave_state->gtid_pos_tables; + old_entry= rpl_global_gtid_slave_state-> + gtid_pos_tables.load(std::memory_order_relaxed); while (old_entry) { if (new_entry->table_hton == old_entry->table_hton) |