aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2004-05-12 08:22:04 +0000
committerDaniel Stenberg <daniel@haxx.se>2004-05-12 08:22:04 +0000
commit34af02caca301a44f54c2df371f957a69e949df1 (patch)
tree4aa0099acc1c3b18f9477b6b815810c6ef73e93f /src
parent91025d1dd65dc4037dfd75accf20116d3a84c7bd (diff)
Disable memdebug for the allocs done by the app, unless CURLTOOLDEBUG is
defined (which it never is atm). Now, we can focus on making 'runtests -t [num]' work on all test cases and we should never leak nor crash.
Diffstat (limited to 'src')
-rw-r--r--src/getpass.c4
-rw-r--r--src/homedir.c4
-rw-r--r--src/main.c3
-rw-r--r--src/urlglob.c5
4 files changed, 9 insertions, 7 deletions
diff --git a/src/getpass.c b/src/getpass.c
index a2854cd16..eb210460e 100644
--- a/src/getpass.c
+++ b/src/getpass.c
@@ -94,8 +94,8 @@ char *getpass_r(const char *prompt, char *buffer, size_t buflen)
#endif
/* The last #include file should be: */
-#ifdef CURLDEBUG
-#include "../lib/memdebug.h"
+#if defined(CURLDEBUG) && defined(CURLTOOLDEBUG)
+#include "memdebug.h"
#endif
char *getpass_r(const char *prompt, char *buffer, size_t buflen)
diff --git a/src/homedir.c b/src/homedir.c
index fedbdb8fc..3ec196a7e 100644
--- a/src/homedir.c
+++ b/src/homedir.c
@@ -42,8 +42,8 @@
#include "homedir.h"
-#ifdef CURLDEBUG
-#include "../lib/memdebug.h"
+#if defined(CURLDEBUG) && defined(CURLTOOLDEBUG)
+#include "memdebug.h"
#endif
static
diff --git a/src/main.c b/src/main.c
index 6cc264b24..9c915203c 100644
--- a/src/main.c
+++ b/src/main.c
@@ -107,6 +107,9 @@
/* The last #include file should be: */
#ifdef CURLDEBUG
+#ifndef CURLTOOLDEBUG
+#define MEMDEBUG_NODEFINES
+#endif
/* This is low-level hard-hacking memory leak tracking and similar. Using
the library level code from this client-side is ugly, but we do this
anyway for convenience. */
diff --git a/src/urlglob.c b/src/urlglob.c
index b7f56192c..582ec1b0b 100644
--- a/src/urlglob.c
+++ b/src/urlglob.c
@@ -35,9 +35,8 @@
#include "urlglob.h"
-
-#ifdef CURLDEBUG
-#include "../lib/memdebug.h"
+#if defined(CURLDEBUG) && defined(CURLTOOLDEBUG)
+#include "memdebug.h"
#endif
typedef enum {