From 472141be033481e2b720a8f6afe672fefcbc8eba Mon Sep 17 00:00:00 2001 From: =?utf8?q?Love=20H=C3=B6rnquist=20=C3=85strand?= Date: Sat, 10 Mar 2012 10:23:57 -0800 Subject: [PATCH] log each error message that is on a very high debug level --- lib/krb5/crypto-stubs.c | 9 +++++++++ lib/krb5/error_string.c | 2 ++ 2 files changed, 11 insertions(+) diff --git a/lib/krb5/crypto-stubs.c b/lib/krb5/crypto-stubs.c index b46268064..ea3101871 100644 --- a/lib/krb5/crypto-stubs.c +++ b/lib/krb5/crypto-stubs.c @@ -90,6 +90,15 @@ krb5_log(krb5_context context, return 0; } +void KRB5_LIB_FUNCTION +_krb5_debug(krb5_context context, + int level, + const char *fmt, + ...) +{ +} + + /* This function is currently just used to get the location of the EGD * socket. If we're not using an EGD, then we can just return NULL */ diff --git a/lib/krb5/error_string.c b/lib/krb5/error_string.c index 9759fb2f5..cbcb288a2 100644 --- a/lib/krb5/error_string.c +++ b/lib/krb5/error_string.c @@ -115,6 +115,8 @@ krb5_vset_error_message (krb5_context context, krb5_error_code ret, if (r < 0) context->error_string = NULL; HEIMDAL_MUTEX_unlock(context->mutex); + if (context->error_string) + _krb5_debug(context, 100, "error message: %s: %d", context->error_string, ret); } /** -- 2.11.4.GIT