Mercurial > hg > nginx
comparison src/http/modules/ngx_http_grpc_module.c @ 7271:9e25a5380a21
Silenced -Wcast-function-type warnings (closes #1546).
Cast to intermediate "void *" to lose compiler knowledge about the original
type and pass the warning. This is not a real fix but rather a workaround.
Found by gcc8.
author | Sergey Kandaurov <pluknet@nginx.com> |
---|---|
date | Mon, 07 May 2018 09:54:37 +0000 |
parents | 070c972336c4 |
children | 6cfd45d4c754 |
comparison
equal
deleted
inserted
replaced
7270:46c0c7ef4913 | 7271:9e25a5380a21 |
---|---|
4387 sizeof(ngx_http_script_copy_code_t)); | 4387 sizeof(ngx_http_script_copy_code_t)); |
4388 if (copy == NULL) { | 4388 if (copy == NULL) { |
4389 return NGX_ERROR; | 4389 return NGX_ERROR; |
4390 } | 4390 } |
4391 | 4391 |
4392 copy->code = (ngx_http_script_code_pt) ngx_http_script_copy_len_code; | 4392 copy->code = (ngx_http_script_code_pt) (void *) |
4393 ngx_http_script_copy_len_code; | |
4393 copy->len = src[i].key.len; | 4394 copy->len = src[i].key.len; |
4394 | 4395 |
4395 size = (sizeof(ngx_http_script_copy_code_t) | 4396 size = (sizeof(ngx_http_script_copy_code_t) |
4396 + src[i].key.len + sizeof(uintptr_t) - 1) | 4397 + src[i].key.len + sizeof(uintptr_t) - 1) |
4397 & ~(sizeof(uintptr_t) - 1); | 4398 & ~(sizeof(uintptr_t) - 1); |