Commit 2c166812 authored by Yang Tse's avatar Yang Tse
Browse files

Adjusted to take in account that...

With the curl memory tracking feature decoupled from the debug build feature,
CURLDEBUG and DEBUGBUILD preprocessor symbol definitions are used as follows:

CURLDEBUG used for curl debug memory tracking specific code (--enable-curldebug)

DEBUGBUILD used for debug enabled specific code (--enable-debug)
parent 065047dc
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -297,7 +297,7 @@ typedef int sig_atomic_t;
 * Macro used to include code only in debug builds.
 */

#ifdef CURLDEBUG
#ifdef DEBUGBUILD
#define DEBUGF(x) x
#else
#define DEBUGF(x) do { } while (0)
@@ -308,7 +308,7 @@ typedef int sig_atomic_t;
 * Macro used to include assertion code only in debug builds.
 */

#if defined(CURLDEBUG) && defined(HAVE_ASSERT_H)
#if defined(DEBUGBUILD) && defined(HAVE_ASSERT_H)
#define DEBUGASSERT(x) assert(x)
#else
#define DEBUGASSERT(x) do { } while (0)
+6 −4
Original line number Diff line number Diff line
@@ -5,7 +5,7 @@
.\" *                            | (__| |_| |  _ <| |___
.\" *                             \___|\___/|_| \_\_____|
.\" *
.\" * Copyright (C) 1998 - 2006, Daniel Stenberg, <daniel@haxx.se>, et al.
.\" * Copyright (C) 1998 - 2009, Daniel Stenberg, <daniel@haxx.se>, et al.
.\" *
.\" * This software is licensed as described in the file COPYING, which
.\" * you should have received as part of this distribution. The terms
@@ -21,7 +21,7 @@
.\" * $Id$
.\" **************************************************************************
.\"
.TH curl_version_info 3 "2 Nov 2006" "libcurl 7.16.1" "libcurl Manual"
.TH curl_version_info 3 "10 June 2009" "libcurl 7.19.6" "libcurl Manual"
.SH NAME
curl_version_info - returns run-time libcurl version info
.SH SYNOPSIS
@@ -105,8 +105,10 @@ supports HTTP NTLM (added in 7.10.6)
.IP CURL_VERSION_GSSNEGOTIATE
supports HTTP GSS-Negotiate (added in 7.10.6)
.IP CURL_VERSION_DEBUG
libcurl was built with extra debug capabilities built-in. This is mainly of
interest for libcurl hackers. (added in 7.10.6)
libcurl was built with debug capabilities (added in 7.10.6)
.IP CURL_VERSION_CURLDEBUG
libcurl was built with memory tracking debug capabilities. This is mainly of
interest for libcurl hackers. (added in 7.19.6)
.IP CURL_VERSION_ASYNCHDNS
libcurl was built with support for asynchronous name lookups, which allows
more exact timeouts (even on Windows) and less blocking when using the multi
+1 −0
Original line number Diff line number Diff line
@@ -425,6 +425,7 @@ CURL_TIMECOND_IFUNMODSINCE 7.9.7
CURL_TIMECOND_LASTMOD           7.9.7
CURL_VERSION_ASYNCHDNS          7.10.7
CURL_VERSION_CONV               7.15.4
CURL_VERSION_CURLDEBUG          7.19.6
CURL_VERSION_DEBUG              7.10.6
CURL_VERSION_GSSNEGOTIATE       7.10.6
CURL_VERSION_IDN                7.12.0
+2 −2
Original line number Diff line number Diff line
@@ -1786,8 +1786,8 @@ typedef struct {
#define CURL_VERSION_LARGEFILE (1<<9)  /* supports files bigger than 2GB */
#define CURL_VERSION_IDN       (1<<10) /* International Domain Names support */
#define CURL_VERSION_SSPI      (1<<11) /* SSPI is supported */
#define CURL_VERSION_CONV      (1<<12) /* character conversions are
                                          supported */
#define CURL_VERSION_CONV      (1<<12) /* character conversions supported */
#define CURL_VERSION_CURLDEBUG (1<<13) /* debug memory tracking supported */

/*
 * NAME curl_version_info()
+2 −2
Original line number Diff line number Diff line
@@ -727,7 +727,7 @@ CURLcode Curl_GetFTPResponse(ssize_t *nreadp, /* return number of bytes read */
static void state(struct connectdata *conn,
                  ftpstate newstate)
{
#if defined(CURLDEBUG) && !defined(CURL_DISABLE_VERBOSE_STRINGS)
#if defined(DEBUGBUILD) && !defined(CURL_DISABLE_VERBOSE_STRINGS)
  /* for debug purposes */
  static const char * const names[]={
    "STOP",
@@ -765,7 +765,7 @@ static void state(struct connectdata *conn,
  };
#endif
  struct ftp_conn *ftpc = &conn->proto.ftpc;
#if defined(CURLDEBUG) && !defined(CURL_DISABLE_VERBOSE_STRINGS)
#if defined(DEBUGBUILD) && !defined(CURL_DISABLE_VERBOSE_STRINGS)
  if(ftpc->state != newstate)
    infof(conn->data, "FTP %p state change from %s to %s\n",
          ftpc, names[ftpc->state], names[newstate]);
Loading