]> git.ipfire.org Git - thirdparty/haproxy.git/commit
MINOR: log: print metadata prefixes separately in sess_build_logline()
authorAurelien DARRAGON <adarragon@haproxy.com>
Tue, 30 Jan 2024 17:01:15 +0000 (18:01 +0100)
committerAurelien DARRAGON <adarragon@haproxy.com>
Tue, 20 Feb 2024 14:49:55 +0000 (15:49 +0100)
commit8d2b9e2acddf354581c694928d05b9f468d501fd
tree0fcd40127af1ed640a735f0746dfe6c871317c49
parenta2fc40bc2808bd508ead528cce067b4b3437e518
MINOR: log: print metadata prefixes separately in sess_build_logline()

Some log variables may be prefixed with specific chars that represent
extra informations that are relevant with it but are are not directly
part of the "raw" value.

ie: '+' char is prepended before some values when "option logasap" is
used to indicate that the value has not yet reached its final value.

However, as those "metadata" are printed using the general purpose
LOGCHAR() printing helper, it's not easy to tell if they are part of the
base value or not.

In this patch we add the LOGMETACHAR() helper that is a wrapper for
LOGCHAR(). The goal is to prepare for adding some logic to prevent such
additional infos from being generated when not relevant or needed.
src/log.c