diff options
author | Sachin Setiya <sachin.setiya@mariadb.com> | 2017-05-08 18:02:46 +0530 |
---|---|---|
committer | Sachin Setiya <sachin.setiya@mariadb.com> | 2017-05-08 18:15:32 +0530 |
commit | 77d6d403c6a8b6462c790ddaa62efe6741350b9f (patch) | |
tree | f1734aae875330e425729b858cbca3d5a5d3ed92 | |
parent | 7a29ca277698ffac757b2bd17c0977fb02b78557 (diff) | |
download | mariadb-git-bb-mdev-12290.tar.gz |
MDEV-12290 Wrong timestamps in binary log causes replication issuesbb-mdev-12290
Binlog_background_thread does not make a call to set_time(), And when
we call binlog_checkpoint_log_event->write() , we write the wrong timestamp.
In this patch we correct this by calling thd->set_time().
-rw-r--r-- | sql/log.cc | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sql/log.cc b/sql/log.cc index a6ece712099..f865c52ac6d 100644 --- a/sql/log.cc +++ b/sql/log.cc @@ -9623,6 +9623,8 @@ binlog_background_thread(void *arg __attribute__((unused))) { THD_STAGE_INFO(thd, stage_binlog_processing_checkpoint_notify); DEBUG_SYNC(thd, "binlog_background_thread_before_mark_xid_done"); + /* Set the thread start time */ + thd->set_time(); /* Grab next pointer first, as mark_xid_done() may free the element. */ next= queue->next_in_queue; mysql_bin_log.mark_xid_done(queue->binlog_id, true); |