diff options
Diffstat (limited to 'syncCommand.h')
-rw-r--r-- | syncCommand.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/syncCommand.h b/syncCommand.h index 6e1e3ea..c556cfb 100644 --- a/syncCommand.h +++ b/syncCommand.h @@ -4,6 +4,7 @@ #include <boost/archive/text_iarchive.hpp> #include "connectionList.h" +#include "threadUtils.hpp" class SyncCommand { @@ -13,12 +14,15 @@ public: u_int16_t getMux() const; private: + SyncCommand(const SyncCommand &); + ::Mutex mutex_; ConnectionList & cl_; u_int16_t mux_; friend class boost::serialization::access; template<class Archive> void serialize(Archive & ar, const unsigned int version) { + Lock lock(mutex_); ar & mux_; ConnectionParam & conn = cl_.getOrNewConnection(mux_); ar & conn; |