summaryrefslogtreecommitdiff
path: root/storage/innobase/trx/trx0sys.cc
diff options
context:
space:
mode:
authorMarko Mäkelä <marko.makela@mariadb.com>2018-02-20 10:02:42 +0200
committerMarko Mäkelä <marko.makela@mariadb.com>2018-02-20 10:30:08 +0200
commit60a68fdf710d60ae6abf839712920a7908308d66 (patch)
tree75180c4a07fb071956ea4ade58fa48c4462b07cd /storage/innobase/trx/trx0sys.cc
parentd23fcc427cb4010b33defc69547089afeb9af811 (diff)
downloadmariadb-git-60a68fdf710d60ae6abf839712920a7908308d66.tar.gz
Clarify the access to trx_sys.rseg_history_len
trx_sys_t::rseg_history_len: Make private, and clarify the documentation. trx_sys_t::history_size(): Read rseg_history_len. trx_sys_t::history_insert(), trx_sys_t::history_remove(), trx_sys_t::history_add(): Update rseg_history_len.
Diffstat (limited to 'storage/innobase/trx/trx0sys.cc')
-rw-r--r--storage/innobase/trx/trx0sys.cc3
1 files changed, 1 insertions, 2 deletions
diff --git a/storage/innobase/trx/trx0sys.cc b/storage/innobase/trx/trx0sys.cc
index d19c2ad23ee..1b60e2bd121 100644
--- a/storage/innobase/trx/trx0sys.cc
+++ b/storage/innobase/trx/trx0sys.cc
@@ -402,6 +402,7 @@ trx_sys_t::create()
mutex_create(LATCH_ID_TRX_SYS, &mutex);
UT_LIST_INIT(mysql_trx_list, &trx_t::mysql_trx_list);
UT_LIST_INIT(m_views, &ReadView::m_view_list);
+ my_atomic_store32(&rseg_history_len, 0);
rw_trx_hash.init();
}
@@ -529,8 +530,6 @@ trx_sys_t::close()
ut_a(UT_LIST_GET_LEN(mysql_trx_list) == 0);
ut_ad(UT_LIST_GET_LEN(m_views) == 0);
-
- /* We used placement new to create this mutex. Call the destructor. */
mutex_free(&mutex);
m_initialised = false;
}