diff src/http/ngx_http_core_module.c @ 446:15a022ee809b NGINX_0_7_35

nginx 0.7.35 *) Bugfix: a "ssl_engine" directive did not use a SSL-accelerator for asymmetric ciphers. Thanks to Marcin Gozdalik. *) Bugfix: a "try_files" directive set MIME type depending on an original request extension. *) Bugfix: "*domain.tld" names were handled incorrectly in "server_name", "valid_referers", and "map" directives, if an ".domain.tld" and ".subdomain.domain.tld" wildcards were used; the bug had appeared in 0.7.9.
author Igor Sysoev <http://sysoev.ru>
date Mon, 16 Feb 2009 00:00:00 +0300
parents 33394d1255b0
children 76a79816b771
line wrap: on
line diff
--- a/src/http/ngx_http_core_module.c
+++ b/src/http/ngx_http_core_module.c
@@ -1197,6 +1197,11 @@ ngx_http_core_try_files_phase(ngx_http_r
             ngx_memcpy(p, name, path.len);
         }
 
+        if (ngx_http_set_exten(r) != NGX_OK) {
+            ngx_http_finalize_request(r, NGX_HTTP_INTERNAL_SERVER_ERROR);
+            return NGX_OK;
+        }
+
         ngx_log_debug1(NGX_LOG_DEBUG_HTTP, r->connection->log, 0,
                        "try file uri: \"%V\"", &r->uri);