aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--driver.c16
1 files changed, 10 insertions, 6 deletions
diff --git a/driver.c b/driver.c
index 68a388d1..db8d52b8 100644
--- a/driver.c
+++ b/driver.c
@@ -53,6 +53,8 @@
#include "getaddrinfo.h"
#include "tunable.h"
+#include "sdump.h"
+
/* throw types for runtime errors */
#define THROW_TIMEOUT 1 /* server timed out */
@@ -246,15 +248,17 @@ const char *canonical; /* server name */
if (retval) {
#ifdef HEIMDAL
if (err_ret && err_ret->e_text) {
+ char *t = err_ret->e_text;
+ char *tt = sdump(t, strlen(t));
report(stderr, GT_("krb5_sendauth: %s [server says '%s']\n"),
- error_message(retval),
- err_ret->e_text);
+ error_message(retval), tt);
+ free(tt);
#else
if (err_ret && err_ret->text.length) {
- report(stderr, GT_("krb5_sendauth: %s [server says '%*s']\n"),
- error_message(retval),
- err_ret->text.length,
- err_ret->text.data);
+ char *tt = sdump(err_ret->text.data, err_ret->text.length);
+ report(stderr, GT_("krb5_sendauth: %s [server says '%s']\n"),
+ error_message(retval), tt);
+ free(tt);
#endif
krb5_free_error(context, err_ret);
} else