mirror of
https://github.com/owasp-modsecurity/ModSecurity.git
synced 2025-08-16 07:56:12 +03:00
Fix building with nginx >= 1.11.11
Closes SpiderLabs/ModSecurity#1359 See also: http://hg.nginx.org/nginx/rev/e662cbf1b932
This commit is contained in:
parent
b6053df941
commit
1bb2ffcd6b
@ -528,9 +528,15 @@ ngx_http_modsecurity_save_request_body(ngx_http_request_t *r)
|
|||||||
|
|
||||||
hc = r->http_connection;
|
hc = r->http_connection;
|
||||||
|
|
||||||
|
#if defined(nginx_version) && nginx_version >= 1011011
|
||||||
|
if (hc->free && size == cscf->large_client_header_buffers.size) {
|
||||||
|
|
||||||
|
buf = hc->free->buf;
|
||||||
|
#else
|
||||||
if (hc->nfree && size == cscf->large_client_header_buffers.size) {
|
if (hc->nfree && size == cscf->large_client_header_buffers.size) {
|
||||||
|
|
||||||
buf = hc->free[--hc->nfree];
|
buf = hc->free[--hc->nfree];
|
||||||
|
#endif
|
||||||
|
|
||||||
ngx_log_debug2(NGX_LOG_DEBUG_HTTP, r->connection->log, 0,
|
ngx_log_debug2(NGX_LOG_DEBUG_HTTP, r->connection->log, 0,
|
||||||
"ModSecurity: use http free large header buffer: %p %uz",
|
"ModSecurity: use http free large header buffer: %p %uz",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user