From a070e6c05ff054ea047defc78fe60ec2d67c4565 Mon Sep 17 00:00:00 2001 From: Hallvard Furuseth Date: Thu, 6 Apr 2006 09:28:19 +0000 Subject: [PATCH] Avoid sprintf buffer overrun if huge hostname --- servers/slurpd/st.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/servers/slurpd/st.c b/servers/slurpd/st.c index 595b99ea0f..d355ce68a5 100644 --- a/servers/slurpd/st.c +++ b/servers/slurpd/st.c @@ -246,10 +246,10 @@ St_read( } if ( found ) { char tbuf[ 255 ]; - sprintf( tbuf, "%s:%s (timestamp %s.%s)", hostname, port, - timestamp, seq ); + sprintf( tbuf, "%s.%s", timestamp, seq ); Debug( LDAP_DEBUG_ARGS, - "Retrieved state information for %s\n", tbuf, 0, 0 ); + "Retrieved state information for %s:%s (timestamp %s)\n", + hostname, port, tbuf ); } else { Debug( LDAP_DEBUG_ANY, "Warning: saved state for %s:%s, not a known replica\n", -- 2.39.5