]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - include/threadengines/threadengine_win32.h
Fix compile error
[user/henk/code/inspircd.git] / include / threadengines / threadengine_win32.h
index 2dd40968e7e376891f6b1e9dcfd0278376bb78a3..3102dc3bb610c9d92e24edc596abea17e603eff3 100644 (file)
@@ -2,7 +2,7 @@
  *       | Inspire Internet Relay Chat Daemon |
  *       +------------------------------------+
  *
- *  InspIRCd: (C) 2002-2008 InspIRCd Development Team
+ *  InspIRCd: (C) 2002-2009 InspIRCd Development Team
  * See: http://www.inspircd.org/wiki/index.php/Credits
  *
  * This program is free but copyrighted software; see
@@ -11,8 +11,8 @@
  * ---------------------------------------------------
  */
 
-#ifndef __THREADENGINE_PTHREAD__
-#define __THREADENGINE_PTHREAD__
+#ifndef __THREADENGINE_WIN32THREAD__
+#define __THREADENGINE_WIN32THREAD__
 
 #include "inspircd_config.h"
 #include "base.h"
@@ -22,14 +22,16 @@ class InspIRCd;
 
 class CoreExport Win32ThreadEngine : public ThreadEngine
 {
+ protected:
+
+       bool Mutex(bool enable);
+
  public:
 
        Win32ThreadEngine(InspIRCd* Instance);
 
        virtual ~Win32ThreadEngine();
 
-       bool Mutex(bool enable);
-
        void Run();
 
        static DWORD WINAPI Entry(void* parameter);
@@ -44,7 +46,7 @@ class CoreExport Win32ThreadEngine : public ThreadEngine
        }
 };
 
-class ThreadEngineFactory : public classbase
+class CoreExport ThreadEngineFactory : public classbase
 {
  public:
        ThreadEngine* Create(InspIRCd* ServerInstance)
@@ -53,5 +55,24 @@ class ThreadEngineFactory : public classbase
        }
 };
 
+class CoreExport Win32Mutex : public Mutex
+{
+ private:
+       CRITICAL_SECTION wutex;
+ public:
+       Win32Mutex(InspIRCd* Instance);
+       virtual void Enable(bool enable);
+       ~Win32Mutex();
+};
+
+class CoreExport MutexFactory : public Extensible
+{
+ protected:
+       InspIRCd* ServerInstance;
+ public:
+       MutexFactory(InspIRCd* Instance);
+       virtual Mutex* CreateMutex();
+};
+
 #endif