comparison src/http/modules/ngx_http_static_module.c @ 248:acd2ec3541cb NGINX_0_4_9

nginx 0.4.9 *) Feature: the "set" parameter in the "include" SSI command. *) Feature: the ngx_http_perl_module now tests the nginx.pm module version.
author Igor Sysoev <http://sysoev.ru>
date Fri, 13 Oct 2006 00:00:00 +0400
parents c16038b14e68
children c5c2b2883984
comparison
equal deleted inserted replaced
247:fcca101509a4 248:acd2ec3541cb
71 71
72 static ngx_int_t 72 static ngx_int_t
73 ngx_http_static_handler(ngx_http_request_t *r) 73 ngx_http_static_handler(ngx_http_request_t *r)
74 { 74 {
75 u_char *last, *location; 75 u_char *last, *location;
76 size_t root;
76 ngx_fd_t fd; 77 ngx_fd_t fd;
77 ngx_int_t rc; 78 ngx_int_t rc;
78 ngx_uint_t level; 79 ngx_uint_t level;
79 ngx_str_t path; 80 ngx_str_t path;
80 ngx_err_t err; 81 ngx_err_t err;
110 /* 111 /*
111 * ngx_http_map_uri_to_path() allocates memory for terminating '\0' 112 * ngx_http_map_uri_to_path() allocates memory for terminating '\0'
112 * so we do not need to reserve memory for '/' for possible redirect 113 * so we do not need to reserve memory for '/' for possible redirect
113 */ 114 */
114 115
115 last = ngx_http_map_uri_to_path(r, &path, 0); 116 last = ngx_http_map_uri_to_path(r, &path, &root, 0);
116 if (last == NULL) { 117 if (last == NULL) {
117 return NGX_HTTP_INTERNAL_SERVER_ERROR; 118 return NGX_HTTP_INTERNAL_SERVER_ERROR;
118 } 119 }
119 120
120 ngx_log_debug1(NGX_LOG_DEBUG_HTTP, log, 0, 121 ngx_log_debug1(NGX_LOG_DEBUG_HTTP, log, 0,