Re: решение ограничения в 10 перенаправлений c помощью пересборки nginx

314zd271c nginx-forum на forum.nginx.org
Чт Фев 7 19:22:41 UTC 2019


Vadim Lazovskiy Wrote:
-------------------------------------------------------
> >
> > cc -c -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter
> -Werror -g
> > -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs
> -I
> > src/http -I src/http/modules \
> >         -o objs/src/http/ngx_http_core_module.o \
> >         src/http/ngx_http_core_module.c
> > src/http/ngx_http_core_module.c: В функции «ngx_http_subrequest»:
> > src/http/ngx_http_core_module.c:2368:5: ошибка: неявное приведение
> большого
> > целого значения к беззнаковому типу [-Werror=overflow]
> >         sr->uri_changes = NGX_HTTP_MAX_URI_CHANGES + 1;
> >         ^
> > cc1: all warnings being treated as errors
> > make[1]: *** [objs/src/http/ngx_http_core_module.o] Ошибка 1
> > make[1]: Выход из каталога '/*****/nginx-1.15.8'
> > make: *** [build] Ошибка 2
> >
> >
> Здравствуйте.
> 
> Под поле uri_changes в ngx_http_request_t
> (src/http/ngx_http_request.h)
> отведено 4 бита:
>  unsigned uri_changes:4;
> 
> Можете попробовать увеличить до 8 или поменять тип на uint8_t

Владимир, 
помогло увеличение поля uri_changes до 8 бит, сборка успешная.
Большое спасибо!

Posted at Nginx Forum: https://forum.nginx.org/read.php?21,282935,282949#msg-282949



Подробная информация о списке рассылки nginx-ru