mirror of
https://github.com/haproxy/haproxy.git
synced 2026-04-15 21:59:41 -04:00
BUILD/DEBUG: lru: fix printf format in debug code
cppcheck reports in issue #1184 a type mismatch between "%d" and the unsigned int "misses" in the standalone debug code of lru.c. Let's switch to "%u".
This commit is contained in:
parent
807a3a53bb
commit
f0683cd510
1 changed files with 1 additions and 1 deletions
|
|
@ -295,7 +295,7 @@ int main(int argc, char **argv)
|
|||
ret += get_value(lru, statistical_prng() & 65535);
|
||||
}
|
||||
/* just for accuracy control */
|
||||
printf("ret=%llx, hits=%d, misses=%d (%d %% hits)\n", ret, total-misses, misses, (int)((float)(total-misses) * 100.0 / total));
|
||||
printf("ret=%llx, hits=%u, misses=%u (%d %% hits)\n", ret, (unsigned)(total-misses), misses, (int)((float)(total-misses) * 100.0 / total));
|
||||
|
||||
while (lru64_destroy(lru));
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue