From: Willy Tarreau Date: Sun, 3 Dec 2017 08:43:38 +0000 (+0100) Subject: BUG/MINOR: hpack: fix debugging output of pseudo header names X-Git-Tag: v1.9-dev1~628 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=9e28f459b4d003072d84fce57811b26ff8245f54;p=thirdparty%2Fhaproxy.git BUG/MINOR: hpack: fix debugging output of pseudo header names When a pseudo header is used, name.ptr is NULL and we must replace it with hpack_idx_to_name(). This only affects code built with DEBUG_HPACK. To be backported to 1.8. --- diff --git a/src/hpack-dec.c b/src/hpack-dec.c index eadb6deb4f..1a776bca76 100644 --- a/src/hpack-dec.c +++ b/src/hpack-dec.c @@ -376,7 +376,7 @@ int hpack_decode_frame(struct hpack_dht *dht, const uint8_t *raw, uint32_t len, } hpack_debug_printf("\e[1;34m%s\e[0m: ", - istpad(trash.str, name).ptr); + istpad(trash.str, name.ptr ? name : hpack_idx_to_name(dht, idx)).ptr); hpack_debug_printf("\e[1;35m%s\e[0m [idx=%d, used=%d]\n", istpad(trash.str, value).ptr,