summaryrefslogtreecommitdiff
path: root/misc.h
diff options
context:
space:
mode:
authorJeffrey Walton <noloader@gmail.com>2020-08-06 03:08:37 -0400
committerJeffrey Walton <noloader@gmail.com>2020-08-06 03:08:37 -0400
commit3f73f709b84ef28a89f9ae04831980d95d97db4c (patch)
tree3591f2c561b6b9ea98e6a89adbe8c2711b2c04f6 /misc.h
parent37368ddb9490a7e54291bc7cce6dacb9731d3fbb (diff)
downloadcryptopp-git-3f73f709b84ef28a89f9ae04831980d95d97db4c.tar.gz
Use CRYPTOPP_CXX11_ATOMIC define
Diffstat (limited to 'misc.h')
-rw-r--r--misc.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/misc.h b/misc.h
index c1f813b0..e5563b0b 100644
--- a/misc.h
+++ b/misc.h
@@ -267,7 +267,7 @@ struct NewObject
/// <tt>_ReadWriteBarrier()</tt> or <tt>__asm__("" ::: "memory")</tt> is used.
#define MEMORY_BARRIER ...
#else
-#if defined(CRYPTOPP_CXX11_ATOMICS)
+#if defined(CRYPTOPP_CXX11_ATOMIC)
# define MEMORY_BARRIER() std::atomic_thread_fence(std::memory_order_acq_rel)
#elif (_MSC_VER >= 1400)
# pragma intrinsic(_ReadWriteBarrier)
@@ -324,7 +324,7 @@ private:
template <class T, class F, int instance>
const T & Singleton<T, F, instance>::Ref(CRYPTOPP_NOINLINE_DOTDOTDOT) const
{
-#if defined(CRYPTOPP_CXX11_ATOMICS) && defined(CRYPTOPP_CXX11_SYNCHRONIZATION) && defined(CRYPTOPP_CXX11_DYNAMIC_INIT)
+#if defined(CRYPTOPP_CXX11_ATOMIC) && defined(CRYPTOPP_CXX11_SYNCHRONIZATION) && defined(CRYPTOPP_CXX11_DYNAMIC_INIT)
static std::mutex s_mutex;
static std::atomic<T*> s_pObject;