summaryrefslogtreecommitdiff
path: root/syncCommand.h
diff options
context:
space:
mode:
authorOthmar Gsenger <otti@anytun.org>2007-12-26 11:57:10 +0000
committerOthmar Gsenger <otti@anytun.org>2007-12-26 11:57:10 +0000
commit38a06aa502da91cb17a960b462d639b4c7cf7726 (patch)
treecab2a37dccebf11b5649d18da16bb6cf2b6c4fd1 /syncCommand.h
parentadded keygeneration at hmac calculation (diff)
added some Locks
Diffstat (limited to 'syncCommand.h')
-rw-r--r--syncCommand.h4
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;