summaryrefslogtreecommitdiff
path: root/sql/log.cc
diff options
context:
space:
mode:
authorSujatha <sujatha.sivakumar@mariadb.com>2020-11-12 14:10:05 +0530
committerSujatha <sujatha.sivakumar@mariadb.com>2020-11-12 14:10:05 +0530
commitbafb011a82c0a6437515c37e37aef433d043f592 (patch)
treef92b3549ab24142a55f0c48a07326b6da290502b /sql/log.cc
parent150f447af1d9ffff168372505e5c9b4297bdd9d4 (diff)
parent984a06db2ce2b2e3c7c5028245905417f2141cd7 (diff)
downloadmariadb-git-bafb011a82c0a6437515c37e37aef433d043f592.tar.gz
Merge branch '10.2' into 10.3
Diffstat (limited to 'sql/log.cc')
-rw-r--r--sql/log.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/sql/log.cc b/sql/log.cc
index d119b88c4e0..8073f09ab88 100644
--- a/sql/log.cc
+++ b/sql/log.cc
@@ -4448,7 +4448,9 @@ int MYSQL_BIN_LOG::purge_first_log(Relay_log_info* rli, bool included)
0, 0, &log_space_reclaimed);
mysql_mutex_lock(&rli->log_space_lock);
- rli->log_space_total-= log_space_reclaimed;
+ my_atomic_add64_explicit((volatile int64*)(&rli->log_space_total),
+ (-(int64)log_space_reclaimed),
+ MY_MEMORY_ORDER_RELAXED);
mysql_cond_broadcast(&rli->log_space_cond);
mysql_mutex_unlock(&rli->log_space_lock);