Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Build fails with nginx 1.23.0 #109

Closed
darix opened this issue Jun 21, 2022 · 1 comment · Fixed by #110
Closed

Build fails with nginx 1.23.0 #109

darix opened this issue Jun 21, 2022 · 1 comment · Fixed by #110

Comments

@darix
Copy link

darix commented Jun 21, 2022

cc -c -fPIC -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g -O2 -Wall -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=3 -fstack-protector-strong -funwind-tables -fasynchronous-unwind-tables -fstack-clash-protection -Werror=return-type -flto=auto -g -fPIC -D_GNU_SOURCE -I src/core -I src/event -I src/e
 -o objs/addon/ngx_http_geoip2_module/ngx_http_geoip2_module.o \
 ../ngx_http_geoip2_module/ngx_http_geoip2_module.c
../ngx_http_geoip2_module/ngx_http_geoip2_module.c: In function 'ngx_http_geoip2_variable':
../ngx_http_geoip2_module/ngx_http_geoip2_module.c:172:14: error: assignment to 'ngx_array_t *' from incompatible pointer type 'ngx_table_elt_t **' {aka 'struct ngx_table_elt_s **'} [-Werror=incompatible-pointer-types]
  172 |         xfwd = &r->headers_in.x_forwarded_for;
      |              ^
../ngx_http_geoip2_module/ngx_http_geoip2_module.c:175:58: error: passing argument 3 of 'ngx_http_get_forwarded_addr' from incompatible pointer type [-Werror=incompatible-pointer-types]
  175 |             (void) ngx_http_get_forwarded_addr(r, &addr, xfwd, NULL,
      |                                                          ^~~~
      |                                                          |
      |                                                          ngx_array_t *
In file included from src/http/ngx_http.h:36,
                 from ../ngx_http_geoip2_module/ngx_http_geoip2_module.c:10:
src/http/ngx_http_core_module.h:532:22: note: expected 'ngx_table_elt_t *' {aka 'struct ngx_table_elt_s *'} but argument is of type 'ngx_array_t *'
  532 |     ngx_table_elt_t *headers, ngx_str_t *value, ngx_array_t *proxies,
      |     ~~~~~~~~~~~~~~~~~^~~~~~~
cc1: all warnings being treated as errors
@DrakeJones
Copy link

A problem with nginx 1.24.0, too.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants