summaryrefslogtreecommitdiff
path: root/dbug
diff options
context:
space:
mode:
authorSergei Golubchik <sergii@pisem.net>2011-11-02 12:26:30 +0100
committerSergei Golubchik <sergii@pisem.net>2011-11-02 12:26:30 +0100
commit7714adaef85cb7d83b1624db2198aec40ddefa24 (patch)
tree8a9059db14b7e408d98e964777efcda3bf7c9760 /dbug
parent952e4067ad54f87394bf48a2a6beb286a1613d8f (diff)
downloadmariadb-git-7714adaef85cb7d83b1624db2198aec40ddefa24.tar.gz
build on windows
Diffstat (limited to 'dbug')
-rw-r--r--dbug/dbug.c12
-rw-r--r--dbug/my_main.c7
2 files changed, 8 insertions, 11 deletions
diff --git a/dbug/dbug.c b/dbug/dbug.c
index 63b373921be..16ac5277707 100644
--- a/dbug/dbug.c
+++ b/dbug/dbug.c
@@ -86,6 +86,8 @@
#include <m_string.h>
#include <errno.h>
+#ifndef DBUG_OFF
+
#ifdef HAVE_FNMATCH_H
#include <fnmatch.h>
#else
@@ -424,7 +426,7 @@ void _db_process_(const char *name)
* 0 - a list of functions was not changed
*/
-int DbugParse(CODE_STATE *cs, const char *control)
+static int DbugParse(CODE_STATE *cs, const char *control)
{
const char *end;
int rel, f_used=0;
@@ -661,8 +663,8 @@ int DbugParse(CODE_STATE *cs, const char *control)
(ListFlags(cs->stack->functions) & INCLUDE) ? \
0 : (uint)TRACE_ON)
-void FixTraceFlags_helper(CODE_STATE *cs, const char *func,
- struct _db_stack_frame_ *framep)
+static void FixTraceFlags_helper(CODE_STATE *cs, const char *func,
+ struct _db_stack_frame_ *framep)
{
if (framep->prev)
FixTraceFlags_helper(cs, framep->func, framep->prev);
@@ -687,7 +689,7 @@ void FixTraceFlags_helper(CODE_STATE *cs, const char *func,
#define fflags(cs) cs->stack->out_file ? ListFlags(cs->stack->functions) : TRACE_ON;
-void FixTraceFlags(uint old_fflags, CODE_STATE *cs)
+static void FixTraceFlags(uint old_fflags, CODE_STATE *cs)
{
const char *func;
uint new_fflags, traceon, level;
@@ -2491,3 +2493,5 @@ static void sf_terminate()
return;
}
+
+#endif /* DBUG_OFF */
diff --git a/dbug/my_main.c b/dbug/my_main.c
index 48d092ca10a..d8bffe662e2 100644
--- a/dbug/my_main.c
+++ b/dbug/my_main.c
@@ -3,10 +3,6 @@
fixed so that it could compile and run in MySQL source tree
*/
-#ifdef DBUG_OFF /* We are testing dbug */
-#undef DBUG_OFF
-#endif
-
#include <my_global.h> /* This includes dbug.h */
#include <my_pthread.h>
@@ -16,9 +12,6 @@ char *argv[];
{
register int result, ix;
extern int factorial(int);
-#if defined(HAVE_PTHREAD_INIT)
- pthread_init(); /* Must be called before DBUG_ENTER */
-#endif
my_thread_global_init();
{