diff options
author | 蕭澧邦 <shou692199@gmail.com> | 2024-11-03 14:36:17 +0800 |
---|---|---|
committer | Roman Arutyunyan <arutyunyan.roman@gmail.com> | 2024-11-11 22:29:55 +0400 |
commit | ea15896c1a5b0ce504f85c1437bae21a542cf3e6 (patch) | |
tree | 418e0f2fe48a2783af36a2fd9ba700c262ef644b /src/stream/ngx_stream_ssl_module.c | |
parent | 29aec5720fdfc74dca8d99d5cf6dc0fcb4e4ce2f (diff) | |
download | nginx-ea15896c1a5b0ce504f85c1437bae21a542cf3e6.tar.gz nginx-ea15896c1a5b0ce504f85c1437bae21a542cf3e6.zip |
SSL: fixed MSVC compilation after ebd18ec1812b.
MSVC generates a compilation error in case #if/#endif is used in a macro
parameter.
Diffstat (limited to 'src/stream/ngx_stream_ssl_module.c')
-rw-r--r-- | src/stream/ngx_stream_ssl_module.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/stream/ngx_stream_ssl_module.c b/src/stream/ngx_stream_ssl_module.c index 55bc54a44..8177d580f 100644 --- a/src/stream/ngx_stream_ssl_module.c +++ b/src/stream/ngx_stream_ssl_module.c @@ -882,12 +882,16 @@ ngx_stream_ssl_merge_srv_conf(ngx_conf_t *cf, void *parent, void *child) ngx_conf_merge_value(conf->reject_handshake, prev->reject_handshake, 0); +#ifndef SSL_OP_NO_TLSv1_2 ngx_conf_merge_bitmask_value(conf->protocols, prev->protocols, (NGX_CONF_BITMASK_SET -#ifndef SSL_OP_NO_TLSv1_2 |NGX_SSL_TLSv1|NGX_SSL_TLSv1_1 -#endif |NGX_SSL_TLSv1_2|NGX_SSL_TLSv1_3)); +#else + ngx_conf_merge_bitmask_value(conf->protocols, prev->protocols, + (NGX_CONF_BITMASK_SET + |NGX_SSL_TLSv1_2|NGX_SSL_TLSv1_3)); +#endif ngx_conf_merge_uint_value(conf->verify, prev->verify, 0); ngx_conf_merge_uint_value(conf->verify_depth, prev->verify_depth, 1); |