From: Greg Hudson Date: Tue, 8 May 2012 03:04:12 +0000 (+0000) Subject: Improve display of error code 0 in trace output X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=faeacc69b5c9e386ea2977506b24dea055bf926b;p=krb5.git Improve display of error code 0 in trace output git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@25853 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/lib/krb5/os/trace.c b/src/lib/krb5/os/trace.c index 309ffa154..a231ca04d 100644 --- a/src/lib/krb5/os/trace.c +++ b/src/lib/krb5/os/trace.c @@ -178,7 +178,8 @@ trace_format(krb5_context context, const char *fmt, va_list ap) } else if (strcmp(tmpbuf, "kerr") == 0) { kerr = va_arg(ap, krb5_error_code); p = krb5_get_error_message(context, kerr); - krb5int_buf_add_fmt(&buf, "%ld/%s", (long) kerr, p); + krb5int_buf_add_fmt(&buf, "%ld/%s", (long) kerr, + kerr ? p : "Success"); krb5_free_error_message(context, p); } else if (strcmp(tmpbuf, "keyblock") == 0) { keyblock = va_arg(ap, const krb5_keyblock *);