libmicrohttpd

HTTP/1.x server C library (MHD 1.x, stable)
Log | Files | Refs | Submodules | README | LICENSE

commit 2dedef2d861073db618bf67360877701c88d683e
parent 66c6efbcf715ed15414db64b10d31cba077d6c22
Author: Christian Grothoff <christian@grothoff.org>
Date:   Sun, 13 Jun 2010 08:07:01 +0000

cleaner

Diffstat:
Msrc/daemon/connection.c | 4+++-
1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/src/daemon/connection.c b/src/daemon/connection.c @@ -450,7 +450,9 @@ try_ready_chunked_body (struct MHD_Connection *connection) } if (ret > 0xFFFFFF) ret = 0xFFFFFF; - SPRINTF (cbuf, "%X\r\n", ret); + snprintf (cbuf, + sizeof (cbuf), + "%X\r\n", ret); cblen = strlen (cbuf); EXTRA_CHECK (cblen <= sizeof (cbuf)); memcpy (&connection->write_buffer[sizeof (cbuf) - cblen], cbuf, cblen);