]> git.ipfire.org Git - thirdparty/haproxy.git/commit
BUG/MINOR: qpack: fix buffer API usage on prefix integer encoding
authorAmaury Denoyelle <adenoyelle@haproxy.com>
Mon, 30 May 2022 09:58:06 +0000 (11:58 +0200)
committerAmaury Denoyelle <adenoyelle@haproxy.com>
Mon, 30 May 2022 12:28:46 +0000 (14:28 +0200)
commit5f6de8d77a75d13e95658ba04beb22b24f37e77d
tree5fc25aa74e8d579592dc4c544a779bf01bbf3cf1
parente06ca65e8dd15f8ae199b1c596ac4f4536a848ac
BUG/MINOR: qpack: fix buffer API usage on prefix integer encoding

Replace bogus call b_data() by b_room() to check if there is enough
space left in the buffer before encoding a prefix integer.

At this moment, no real scenario was found to trigger a bug related to
this change. This is probably because the buffer always contains data
(field section line and status code) before calling
qpack_encode_prefix_integer() which prevents an occurrence of this bug.
src/qpack-enc.c