krb5 commit: Fix type error in klog com_err hook

Greg Hudson <[email protected]>
Newsgroups gmane.comp.encryption.kerberos.cvs
Message-ID <[email protected]>
https://github.com/krb5/krb5/commit/5a5be01e888a575b72407088749066213c57284f
commit 5a5be01e888a575b72407088749066213c57284f
Author: Greg Hudson <[email protected]>
Date:   Fri Jan 19 13:01:43 2018 -0500

    Fix type error in klog com_err hook
    
    As a variable argument, buf.data won't be automatically cast from
    void * to char * when passed to krb5_klog_syslog(), so to be correct
    we must do it manually.
    
    ticket: 8630

 src/lib/kadm5/logger.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/lib/kadm5/logger.c b/src/lib/kadm5/logger.c
index 771ab67..2da8f92 100644
--- a/src/lib/kadm5/logger.c
+++ b/src/lib/kadm5/logger.c
@@ -201,7 +201,7 @@ klog_com_err_proc(const char *whoami, long int code, const char *format, va_list
     k5_buf_add_vfmt(&buf, format, ap);
 
     if (k5_buf_status(&buf) == 0)
-        krb5_klog_syslog(code ? LOG_ERR : LOG_INFO, "%s", buf.data);
+        krb5_klog_syslog(code ? LOG_ERR : LOG_INFO, "%s", (char *)buf.data);
 
     k5_buf_free(&buf);
 }
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.