summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorphintuka <phintuka>2010-03-15 12:07:44 +0000
committerphintuka <phintuka>2010-03-15 12:07:44 +0000
commit1a6a6d9e2c3943d6cf53a8c00726cff1b32cf31a (patch)
tree8bd6e640752df3a12cb891b2b9833a109cc6a5ea
parent2eaa19c1dd44f8b0f14abfcc7e8a7399bc1df7ba (diff)
downloadxineliboutput-1a6a6d9e2c3943d6cf53a8c00726cff1b32cf31a.tar.gz
xineliboutput-1a6a6d9e2c3943d6cf53a8c00726cff1b32cf31a.tar.bz2
Initial import
-rw-r--r--tools/section_lock.h24
1 files changed, 24 insertions, 0 deletions
diff --git a/tools/section_lock.h b/tools/section_lock.h
new file mode 100644
index 00000000..a054005d
--- /dev/null
+++ b/tools/section_lock.h
@@ -0,0 +1,24 @@
+/*
+ * section_lock.h:
+ *
+ * See the main source file 'xineliboutput.c' for copyright information and
+ * how to reach the author.
+ *
+ * $Id: section_lock.h,v 1.1 2010-03-15 12:07:44 phintuka Exp $
+ *
+ */
+
+#ifndef __SECTION_LOCK_H
+#define __SECTION_LOCK_H
+
+#include <vdr/thread.h>
+
+class cSectionLock {
+ private:
+ cMutex& mutex;
+ public:
+ cSectionLock(cMutex& Mutex) : mutex(Mutex) { mutex.Lock(); };
+ ~cSectionLock() { mutex.Unlock(); };
+};
+
+#endif // __SECTION_LOCK_H