From 82bdb48dabacd521f93c02b1520aec0db4996bf9 Mon Sep 17 00:00:00 2001 From: Robin Gareus Date: Mon, 29 Jul 2019 04:45:29 +0200 Subject: [PATCH] Partially undo 6d4b94df13 for MSVC and C++98 compat --- libs/pbd/spinlock.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libs/pbd/spinlock.cc b/libs/pbd/spinlock.cc index 0e53b194b9..ff6fe51b1b 100644 --- a/libs/pbd/spinlock.cc +++ b/libs/pbd/spinlock.cc @@ -36,7 +36,8 @@ spinlock_t::spinlock_t () #else /* default C++ assign struct's first member */ { - l = BOOST_DETAIL_SPINLOCK_INIT; + boost::detail::spinlock init = BOOST_DETAIL_SPINLOCK_INIT; + std::memcpy (&l, &init, sizeof (init)); } #endif