summaryrefslogtreecommitdiff
path: root/src/syncQueue.cpp
diff options
context:
space:
mode:
authorOthmar Gsenger <otti@anytun.org>2009-01-12 21:41:30 +0000
committerOthmar Gsenger <otti@anytun.org>2009-01-12 21:41:30 +0000
commit33cad772126bd4b87249a3798b43edda59396e89 (patch)
tree2cc7862d0f66f3dd270a2e52208f333e166a981a /src/syncQueue.cpp
parentmoved rtp stuff to anyrtpproxy and removed it from anytun (diff)
fixed anytun-nosync build target
Diffstat (limited to 'src/syncQueue.cpp')
-rw-r--r--src/syncQueue.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/syncQueue.cpp b/src/syncQueue.cpp
index d90caaf..636107b 100644
--- a/src/syncQueue.cpp
+++ b/src/syncQueue.cpp
@@ -42,6 +42,21 @@
#include "syncQueue.h"
+SyncQueue* SyncQueue::inst = NULL;
+Mutex SyncQueue::instMutex;
+SyncQueue& gSyncQueue = SyncQueue::instance();
+
+
+SyncQueue& SyncQueue::instance()
+{
+ Lock lock(instMutex);
+ static instanceCleaner c;
+ if(!inst)
+ inst = new SyncQueue();
+
+ return *inst;
+}
+
void SyncQueue::push(const SyncCommand & scom )
{
std::ostringstream sout;