diff --git a/src/runProc.cpp b/src/runProc.cpp index d7af5e8..a7783d8 100644 --- a/src/runProc.cpp +++ b/src/runProc.cpp @@ -49,6 +49,9 @@ void T_runProc::runProc_slotProcess(void) { #ifndef THIS_IS_CA_MASTER bool const coinAttached = epi_getDI_CoinAttach(); + // exchange: (atomically) replaces the underlying value of m_coinAttached + // with the value of coinAttached, returns the value of m_coinAttached + // before the call if (m_coinAttached.exchange(coinAttached) == false) { if (coinAttached) { // old value was false, and new value is true