]> git.ipfire.org Git - thirdparty/haproxy.git/commit
MINOR: stats admin: reduce memcmp()/strcmp() calls on status codes
authorCyril Bonté <cyril.bonte@free.fr>
Wed, 4 Apr 2012 10:57:21 +0000 (12:57 +0200)
committerWilly Tarreau <w@1wt.eu>
Thu, 5 Apr 2012 07:58:27 +0000 (09:58 +0200)
commit19979e176ee078345868b78787634c60af2e1921
tree9a6cba1ef6a4331a84251be8949980021a31459a
parentaa0a45d2edda92a1239d213bf306338ad912d9ca
MINOR: stats admin: reduce memcmp()/strcmp() calls on status codes

memcmp()/strcmp() calls were needed in different parts of code to determine
the status code. Each new status code introduces new calls, which can become
inefficient and source of bugs.
This patch reorganizes the code to rely on a numeric status code internally
and to be hopefully more generic.
include/proto/dumpstats.h
include/types/proto_http.h
include/types/stream_interface.h
src/dumpstats.c
src/proto_http.c