summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2004-04-17 18:18:26 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2004-04-17 18:18:26 +0000
commite81bad456aa55af8b0cb31d2ffeb0672ff0c6bbf (patch)
tree2330a8e8d362ae33a4a83d92be789c01a9dabd61 /include
parent3345b6c0dc26bf5f5ab848a22b9b5f2887e51574 (diff)
Added calls to sched_yield() to cut down processor usage - won't work in *bsd
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@635 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'include')
-rw-r--r--include/connection.h2
-rw-r--r--include/dynamic.h23
2 files changed, 8 insertions, 17 deletions
diff --git a/include/connection.h b/include/connection.h
index c74a494b1..0d9bdb683 100644
--- a/include/connection.h
+++ b/include/connection.h
@@ -151,7 +151,7 @@ class ircd_connector : public classbase
/** Class packet is deprecated.
* This declaration is preserved here to maintain documentation only.
*/
-class packet
+class packet : public classbase
{
};
diff --git a/include/dynamic.h b/include/dynamic.h
index b34f2358b..0382324ce 100644
--- a/include/dynamic.h
+++ b/include/dynamic.h
@@ -53,13 +53,8 @@ class DLLManager
class DLLFactoryBase : public DLLManager
{
public:
- DLLFactoryBase(
- const char *fname,
- const char *func_name=0
- );
-
+ DLLFactoryBase(const char *fname, const char *func_name = 0);
virtual ~DLLFactoryBase();
-
void * (*factory_func)(void);
};
@@ -83,19 +78,15 @@ class DLLFactoryBase : public DLLManager
// is deleted, because the DLL will get unloaded as well.
//
-template <class T>
-class DLLFactory : public DLLFactoryBase
+template <class T> class DLLFactory : public DLLFactoryBase
{
public:
- DLLFactory(
- const char *fname,
- const char *func_name=0
- ) : DLLFactoryBase( fname, func_name )
+ DLLFactory(const char *fname, const char *func_name=0) : DLLFactoryBase(fname,func_name)
{
- if( factory_func )
- factory = (T *)factory_func();
- else
- factory = 0;
+ if (factory_func)
+ factory = (T*)factory_func();
+ else
+ factory = 0;
}
~DLLFactory()