summaryrefslogtreecommitdiff
path: root/lib/memdebug.c
diff options
context:
space:
mode:
authorYang Tse <yangsita@gmail.com>2011-08-20 17:26:02 +0200
committerYang Tse <yangsita@gmail.com>2011-08-20 17:26:42 +0200
commitaaab5fa299e13c0c3abba929cb187a8ec3b006f9 (patch)
tree9cf9d0bee6c32b828940632087bc1385943023c9 /lib/memdebug.c
parent2d7c79af76ea9c35d0ec9512da2211d7aedf2878 (diff)
downloadcurl-aaab5fa299e13c0c3abba929cb187a8ec3b006f9.tar.gz
MemoryTracking: adjust initialization calling
Calling of curl_memdebug() was still done with a pending free()
Diffstat (limited to 'lib/memdebug.c')
-rw-r--r--lib/memdebug.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/memdebug.c b/lib/memdebug.c
index 9617faf13..1a0a485a8 100644
--- a/lib/memdebug.c
+++ b/lib/memdebug.c
@@ -119,7 +119,7 @@ static long memsize = 0; /* set number of mallocs allowed */
void curl_memdebug(const char *logname)
{
if(!logfile) {
- if(logname)
+ if(logname && *logname)
logfile = fopen(logname, "w");
else
logfile = stderr;