]> git.ipfire.org Git - thirdparty/haproxy.git/commit
BUILD/MEDIUM: standard: get rid of sprintf()
authorWilly Tarreau <w@1wt.eu>
Mon, 14 Apr 2014 12:53:06 +0000 (14:53 +0200)
committerWilly Tarreau <w@1wt.eu>
Mon, 14 Apr 2014 13:52:48 +0000 (15:52 +0200)
commit761b3d557e28d6bb4df7544fdeffd68b34da9f95
tree5d71b58dd101e39033e2cad649d91ab47b03cad9
parent94ef3f3115bc2ce213063f69bfca11c2a4f18396
BUILD/MEDIUM: standard: get rid of sprintf()

OpenBSD complains about the use of sprintf in human_time() :

src/standard.o(.text+0x1c40): In function `human_time':
src/standard.c:2067: warning: sprintf() is often misused, please use snprintf()

We can easily get around this by having a pointer to the end of the string and
using snprintf() instead.
src/standard.c