summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libs/pbd/spinlock.cc3
1 files changed, 2 insertions, 1 deletions
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