From: Willy Tarreau Date: Mon, 8 Nov 2021 08:50:29 +0000 (+0100) Subject: CLEANUP: halog: remove unused strl2ui() X-Git-Tag: v2.5-dev14~39 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=fce4e6914435511e1913803241c1384264a7cb4d;p=thirdparty%2Fhaproxy.git CLEANUP: halog: remove unused strl2ui() strl2ui() isn't used anymore in the code, likely because str2ic() is often used instead. Let's drop it. --- diff --git a/admin/halog/halog.c b/admin/halog/halog.c index c7697dc524..79eff91453 100644 --- a/admin/halog/halog.c +++ b/admin/halog/halog.c @@ -451,22 +451,6 @@ int str2ic(const char *s) } -/* Equivalent to strtoul with a length. */ -static inline unsigned int __strl2ui(const char *s, int len) -{ - unsigned int i = 0; - while (len-- > 0) { - i = i * 10 - '0'; - i += (unsigned char)*s++; - } - return i; -} - -unsigned int strl2ui(const char *s, int len) -{ - return __strl2ui(s, len); -} - /* Convert "[04/Dec/2008:09:49:40.555]" to an integer equivalent to the time of * the day in milliseconds. It returns -1 for all unparsable values. The parser * looks ugly but gcc emits far better code that way.