From 3a634a273a7bff3d219883f572db786e2c1004b1 Mon Sep 17 00:00:00 2001 From: Yang Tse Date: Wed, 21 Feb 2007 19:03:20 +0000 Subject: curlassert macro replaced with DEBUGASSERT macro defined in setup_once.h --- ares/setup_once.h | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'ares/setup_once.h') diff --git a/ares/setup_once.h b/ares/setup_once.h index 32d8293ee..20ea3819d 100644 --- a/ares/setup_once.h +++ b/ares/setup_once.h @@ -200,9 +200,20 @@ typedef int sig_atomic_t; */ #ifdef CURLDEBUG -#define DEBUGF(X) X +#define DEBUGF(x) x #else -#define DEBUGF(X) do { } while (0) +#define DEBUGF(x) do { } while (0) +#endif + + +/* + * Macro used to include assertion code only in debug builds. + */ + +#if defined(CURLDEBUG) && defined(HAVE_ASSERT_H) +#define DEBUGASSERT(x) assert(x) +#else +#define DEBUGASSERT(x) do { } while (0) #endif -- cgit v1.2.3