BUG/MINOR: cache: Wrong usage of shctx_init().
authorFrédéric Lécaille <flecaille@haproxy.com>
Thu, 25 Oct 2018 18:18:59 +0000 (20:18 +0200)
committerWilly Tarreau <w@1wt.eu>
Fri, 26 Oct 2018 02:54:40 +0000 (04:54 +0200)
commitbc584494e625983f16f35982aa6dd6889e8dd222
tree5a185f85ed470627093e1a5c8e525e4b89d09f4b
parentb9b8b6b6beb84b6b942d24eda56bfbe3812cc294
BUG/MINOR: cache: Wrong usage of shctx_init().

With this patch we check that shctx_init() does not returns 0.
This is possible if the maxblocks argument, which is passed as an
int, is negative due to an implicit conversion.

Must be backported to 1.8.
src/cache.c