]> git.ipfire.org Git - thirdparty/haproxy.git/commit
MINOR: mux-quic/h3: adjust demuxing function return values
authorAmaury Denoyelle <adenoyelle@haproxy.com>
Tue, 7 Jun 2022 15:30:55 +0000 (17:30 +0200)
committerAmaury Denoyelle <adenoyelle@haproxy.com>
Tue, 7 Jun 2022 16:15:47 +0000 (18:15 +0200)
commit1f21ebdd7686bf435682cacd31e635db0c65b061
treef9e5a4047a4885881bd54f4ed7693c3f0dffc2e6
parent62eef85961f4a2a241e0b24ef540cc91f156b842
MINOR: mux-quic/h3: adjust demuxing function return values

Clean the API used by decode_qcs() and transcoder internal functions.
Parsing functions now returns a ssize_t which represents the number of
consumed bytes or a negative error code. The total consumed bytes is
returned via decode_qcs().

The API is now unified and cleaner. The MUX can thus simply use the
return value of decode_qcs() instead of substracting the data bytes in
the buffer before and after the call. Transcoders functions are not
anymore obliged to remove consumed bytes from the buffer which was not
obvious.
include/haproxy/mux_quic-t.h
src/h3.c
src/hq_interop.c
src/mux_quic.c