mirror of
https://git.haproxy.org/git/haproxy.git/
synced 2025-11-11 05:51:02 +01:00
Relax the constraint for gap storage when this is the last block. ncb_blk API functions will consider that if a gap is stored near the end of the buffer, without the space to store its header, the gap will cover entirely the buffer end. For these special cases, the gap size/data size are not write/read inside the gap to prevent an overflow. Such a gap is designed in functions as "reduced gap" and will be flagged with the value NCB_BK_F_FIN. This should reduce the rejection on future add operation when receiving data in-order. Without reduced gap handling, an insertion would be rejected if it covers only partially the last buffer bytes, which can be a very common case.