From a36a3e4c838275d33b2ed087b037ed3708b04749 Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Fri, 12 Jun 2009 14:50:46 +0200 Subject: Add debugging facility to tldap, analogous to tevent --- source3/include/tldap.h | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'source3/include') diff --git a/source3/include/tldap.h b/source3/include/tldap.h index c79a142654..d57484c5f8 100644 --- a/source3/include/tldap.h +++ b/source3/include/tldap.h @@ -145,6 +145,21 @@ const char *tldap_ctx_diagnosticmessage(struct tldap_context *ctx); const char *tldap_ctx_referral(struct tldap_context *ctx); const char *tldap_err2string(int rc); +/* DEBUG */ +enum tldap_debug_level { + TLDAP_DEBUG_FATAL, + TLDAP_DEBUG_ERROR, + TLDAP_DEBUG_WARNING, + TLDAP_DEBUG_TRACE +}; + +void tldap_set_debug(struct tldap_context *ld, + void (*log_fn)(void *log_private, + enum tldap_debug_level level, + const char *fmt, + va_list ap) PRINTF_ATTRIBUTE(3,0), + void *log_private); + /* * "+ 0x60" is from ASN1_APPLICATION */ -- cgit