[nginx] Fixed false compiler warning.
Homutov Vladimir
vl at nginx.com
Fri Jan 31 10:43:39 UTC 2014
details: http://hg.nginx.org/nginx/rev/4d47722d76b2
branches:
changeset: 5548:4d47722d76b2
user: Vladimir Homutov <vl at nginx.com>
date: Fri Jan 31 14:18:52 2014 +0400
description:
Fixed false compiler warning.
Newer gcc versions (4.7+) report possible use of uninitialized variable if
nginx is being compiled with -O3.
diffstat:
src/http/ngx_http_request.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diffs (14 lines):
diff -r 2e40188f83ef -r 4d47722d76b2 src/http/ngx_http_request.c
--- a/src/http/ngx_http_request.c Thu Jan 30 19:13:12 2014 +0400
+++ b/src/http/ngx_http_request.c Fri Jan 31 14:18:52 2014 +0400
@@ -1944,6 +1944,10 @@ ngx_http_set_virtual_server(ngx_http_req
ngx_http_core_loc_conf_t *clcf;
ngx_http_core_srv_conf_t *cscf;
+#if (NGX_SUPPRESS_WARN)
+ cscf = NULL;
+#endif
+
hc = r->http_connection;
#if (NGX_HTTP_SSL && defined SSL_CTRL_SET_TLSEXT_HOSTNAME)
More information about the nginx-devel
mailing list