]> granicus.if.org Git - libevent/commit
Add event_enable_debug_logging() to control use of debug logs
authorNick Mathewson <nickm@torproject.org>
Thu, 16 Dec 2010 18:58:56 +0000 (13:58 -0500)
committerNick Mathewson <nickm@torproject.org>
Thu, 16 Dec 2010 18:58:56 +0000 (13:58 -0500)
commite30a82f11829e3dc2cf1add253c768fa144db494
tree27fc34bba15b8e56b1ef685f8f5d29abdb9ee25c
parentb8b8aa560c038c6f0c22a574d99d314a1f4a3b7a
Add event_enable_debug_logging() to control use of debug logs

Previously, debug logs were turned on if you built with -DUSE_DEBUG
and off otherwise.  This make builds with -DUSE_DEBUG hideously slow
and other builds unable to get debug logs.

This is based off a patch by Ralph Castain from October.  It tries a
little harder to avoid needless function calls, it doesn't require
stdbool, and makes the controlling parameter a mask rather than a
boolean so that we can later support enabling only the debugging
messages for the parts of Libevent you're trying to debug.
include/event2/event.h
log-internal.h
log.c