From: Willy Tarreau Date: Thu, 26 Nov 2015 15:34:56 +0000 (+0100) Subject: CLEANUP: compression: don't allocate DEFAULT_MAXZLIBMEM without USE_ZLIB X-Git-Tag: v1.7-dev1~35 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ed9dddd237a699f1eb961b80586ac8c76e9dd996;p=thirdparty%2Fhaproxy.git CLEANUP: compression: don't allocate DEFAULT_MAXZLIBMEM without USE_ZLIB It's pointless to reserve this amount of memory when zlib is not used. Adding the condition will make build scripts easier to manage. This may be backported to 1.6. --- diff --git a/src/haproxy.c b/src/haproxy.c index 973af29182..6e75f72c55 100644 --- a/src/haproxy.c +++ b/src/haproxy.c @@ -134,7 +134,7 @@ struct global global = { .nbproc = 1, .req_count = 0, .logsrvs = LIST_HEAD_INIT(global.logsrvs), -#ifdef DEFAULT_MAXZLIBMEM +#if defined(USE_ZLIB) && defined(DEFAULT_MAXZLIBMEM) .maxzlibmem = DEFAULT_MAXZLIBMEM * 1024U * 1024U, #else .maxzlibmem = 0,