projects
/
exim.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c7c4ae9
)
GnuTLS debug callback: check for existing \n
author
Phil Pennock
<pdp@exim.org>
Sun, 20 May 2012 09:33:22 +0000
(
05:33
-0400)
committer
Phil Pennock
<pdp@exim.org>
Sun, 20 May 2012 09:33:22 +0000
(
05:33
-0400)
src/src/tls-gnu.c
patch
|
blob
|
blame
|
history
diff --git
a/src/src/tls-gnu.c
b/src/src/tls-gnu.c
index 05a3e084c2d9e71a71069763beb60e34494cde9c..51fdb86574d30507be67d2fac0f5841f17213edc 100644
(file)
--- a/
src/src/tls-gnu.c
+++ b/
src/src/tls-gnu.c
@@
-1183,7
+1183,14
@@
return TRUE;
static void
exim_gnutls_logger_cb(int level, const char *message)
{
- DEBUG(D_tls) debug_printf("GnuTLS<%d>: %s\n", level, message);
+ size_t len = strlen(message);
+ if (len < 1)
+ {
+ DEBUG(D_tls) debug_printf("GnuTLS<%d> empty debug message\n", level);
+ return;
+ }
+ DEBUG(D_tls) debug_printf("GnuTLS<%d>: %s%s", level, message,
+ message[len-1] == '\n' ? "" : "\n");
}
#endif