CONTRIB: hpack: make use of the simplified standalone HPACK API
authorWilly Tarreau <w@1wt.eu>
Fri, 22 May 2020 10:09:16 +0000 (12:09 +0200)
committerWilly Tarreau <w@1wt.eu>
Fri, 22 May 2020 10:13:43 +0000 (12:13 +0200)
commit318adf43648143292a6e6b74d4600b4908172598
tree335f8f8793dc6bd4c5bfbd4a6dd95a333f039364
parent0ff9b3d64fdf0707da8c9a0ae00a7cf753200e36
CONTRIB: hpack: make use of the simplified standalone HPACK API

As reported in oss-fuzz issue 22388, the contrib/hpack code doesn't
build anymore for now. Thanks to previous patch we can now just define
HPACK_STANDALONE in the few files which include hpack-tbl.h and we can
declare a dummy pool to hold the DHT size. This is enough to make the
code work again outside of the haproxy process. It was successfully
tested using:

  $ echo 82 84 87 90 | ./decode
contrib/hpack/decode.c
contrib/hpack/gen-enc.c