diff options
author | Maxim Dounin <mdounin@mdounin.ru> | 2019-10-21 19:07:03 +0300 |
---|---|---|
committer | Maxim Dounin <mdounin@mdounin.ru> | 2019-10-21 19:07:03 +0300 |
commit | 2393e25acb89f7434e6330a7754c076575a297fd (patch) | |
tree | 3a0041305c581eac5c446e5472160e1f138a1112 /src | |
parent | 9aa906a684111a2f61ee841067cc0023ebcfa269 (diff) | |
download | nginx-2393e25acb89f7434e6330a7754c076575a297fd.tar.gz nginx-2393e25acb89f7434e6330a7754c076575a297fd.zip |
Win32: silenced -Wcast-function-type GCC warning (ticket #1865).
With MinGW-w64, building 64-bit nginx binary with GCC 8 and above
results in warning due to cast of GetProcAddress() result to ngx_wsapoll_pt,
which GCC thinks is incorrect. Added intermediate cast to "void *" to
silence the warning.
Diffstat (limited to 'src')
-rw-r--r-- | src/os/win32/ngx_win32_init.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/os/win32/ngx_win32_init.c b/src/os/win32/ngx_win32_init.c index 70bee8ef4..3249fb293 100644 --- a/src/os/win32/ngx_win32_init.c +++ b/src/os/win32/ngx_win32_init.c @@ -240,7 +240,7 @@ ngx_os_init(ngx_log_t *log) goto nopoll; } - WSAPoll = (ngx_wsapoll_pt) GetProcAddress(hmod, "WSAPoll"); + WSAPoll = (ngx_wsapoll_pt) (void *) GetProcAddress(hmod, "WSAPoll"); if (WSAPoll == NULL) { ngx_log_error(NGX_LOG_NOTICE, log, ngx_errno, "GetProcAddress(\"WSAPoll\") failed"); |