projects
/
NeonServV5.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
increased MAXLANGUAGES definition
[NeonServV5.git]
/
src
/
overall.h
diff --git
a/src/overall.h
b/src/overall.h
index d500e4771a47cd13d18d69c628ae49d16009da2a..55b48eac97e0771cbecbfe6343e89500e349f496 100644
(file)
--- a/
src/overall.h
+++ b/
src/overall.h
@@
-77,13
+77,21
@@
pthread_mutexattr_settype(&mutex_attr, type);\
pthread_mutex_init(&var, &mutex_attr); \
}
pthread_mutexattr_settype(&mutex_attr, type);\
pthread_mutex_init(&var, &mutex_attr); \
}
+#ifdef ENABLE_MUTEX_DEBUG
+#include "mutexDebug.h"
+#define SYNCHRONIZE(var) xmutex(1, &var, __FILE__, __LINE__); pthread_mutex_lock(&var)
+#define DESYNCHRONIZE(var) xmutex(0, &var, __FILE__, __LINE__); pthread_mutex_unlock(&var)
+#else
#define SYNCHRONIZE(var) pthread_mutex_lock(&var)
#define SYNCHRONIZE(var) pthread_mutex_lock(&var)
-#define SET_SYNCHRONIZE(var) pthread_mutex_trylock(&var)
#define DESYNCHRONIZE(var) pthread_mutex_unlock(&var)
#define DESYNCHRONIZE(var) pthread_mutex_unlock(&var)
+#endif
#else
#define THREAD_MUTEX_INIT(var)
#define SYNCHRONIZE(var)
#define DESYNCHRONIZE(var)
#else
#define THREAD_MUTEX_INIT(var)
#define SYNCHRONIZE(var)
#define DESYNCHRONIZE(var)
+#ifdef ENABLE_MUTEX_DEBUG
+#undef ENABLE_MUTEX_DEBUG
+#endif
#endif
#if __GNUC__
#endif
#if __GNUC__
@@
-134,7
+142,7
@@
#define MAXLOGLEN 1024
#define TRIGGERLEN 50
#define MAXNUMPARAMS 200 /* maximum number of parameters in one line */
#define MAXLOGLEN 1024
#define TRIGGERLEN 50
#define MAXNUMPARAMS 200 /* maximum number of parameters in one line */
-#define MAXLANGUAGES 5
+#define MAXLANGUAGES
1
5
#define MAXMODES 6
#define INVITE_TIMEOUT 30
#define BOTWAR_DETECTION_TIME 7
#define MAXMODES 6
#define INVITE_TIMEOUT 30
#define BOTWAR_DETECTION_TIME 7