summaryrefslogtreecommitdiff
path: root/core/templates
diff options
context:
space:
mode:
Diffstat (limited to 'core/templates')
-rw-r--r--core/templates/safe_refcount.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/core/templates/safe_refcount.h b/core/templates/safe_refcount.h
index 3148283dca..1f6551762e 100644
--- a/core/templates/safe_refcount.h
+++ b/core/templates/safe_refcount.h
@@ -111,6 +111,7 @@ public:
if (tmp >= p_value) {
return tmp; // already greater, or equal
}
+
if (value.compare_exchange_weak(tmp, p_value, std::memory_order_acq_rel)) {
return p_value;
}