]> git.ipfire.org Git - thirdparty/haproxy.git/commit
MINOR: stick-table: make stktable_fetch_key() indicate why it failed
authorWilly Tarreau <w@1wt.eu>
Wed, 25 Jun 2014 14:20:53 +0000 (16:20 +0200)
committerWilly Tarreau <w@1wt.eu>
Wed, 25 Jun 2014 15:17:53 +0000 (17:17 +0200)
commitb5975defba61e7ef37ae771614166d0970ede04e
treec0312f667dd6e5b155bc4764aff0821c55bc96f7
parent6c616e0b96106dd33d183afbda31e72799e967c3
MINOR: stick-table: make stktable_fetch_key() indicate why it failed

stktable_fetch_key() does not indicate whether it returns NULL because
the input sample was not found or because it's unstable. It causes trouble
with track-sc* rules. Just like with sample_fetch_string(), we want it to
be able to give more information to the caller about what it found. Thus,
now we use the pointer to a sample passed by the caller, and fill it with
the information we have about the sample. That way, even if we return NULL,
the caller has the ability to check whether a sample was found and if it is
still changing or not.
include/proto/stick_table.h
src/proto_tcp.c
src/session.c
src/stick_table.c