aboutsummaryrefslogtreecommitdiff
path: root/lib/libfetch/common.h
diff options
context:
space:
mode:
authorDag-Erling Smørgrav <des@FreeBSD.org>2001-12-09 15:05:19 +0000
committerDag-Erling Smørgrav <des@FreeBSD.org>2001-12-09 15:05:19 +0000
commit7eb2f34d73badc8703f376f737e23a4986083b2c (patch)
tree2e0b054dfbc897bf794d519602be9269343d3bab /lib/libfetch/common.h
parentd1f21093cd3cf373dfa2304cc122d8b40ec89014 (diff)
downloadsrc-7eb2f34d73badc8703f376f737e23a4986083b2c.tar.gz
src-7eb2f34d73badc8703f376f737e23a4986083b2c.zip
Introduce a fetchDebug global. Change the DEBUG macro so it only runs the
debugging code if fetchDebug is set. PR: bin/32615 MFC after: 1 week
Notes
Notes: svn path=/head/; revision=87560
Diffstat (limited to 'lib/libfetch/common.h')
-rw-r--r--lib/libfetch/common.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/libfetch/common.h b/lib/libfetch/common.h
index 6dad6845a6b1..84b2e01478e7 100644
--- a/lib/libfetch/common.h
+++ b/lib/libfetch/common.h
@@ -59,7 +59,7 @@ int _fetch_add_entry(struct url_ent **, int *, int *,
#define _url_seterr(n) _fetch_seterr(_url_errlist, n)
#ifndef NDEBUG
-#define DEBUG(x) do x; while (0)
+#define DEBUG(x) do { if (fetchDebug) { x; } } while (0)
#else
#define DEBUG(x) do { } while (0)
#endif