Mercurial > hg > nginx-vendor-0-6
comparison src/core/ngx_file.c @ 28:7ca9bdc82b3f NGINX_0_1_14
nginx 0.1.14
*) Feature: the autoconfiguration directives:
--http-client-body-temp-path=PATH, --http-proxy-temp-path=PATH, and
--http-fastcgi-temp-path=PATH
*) Change: the directory name for the temporary files with the client
request body is specified by directive client_body_temp_path, by
default it is <prefix>/client_body_temp.
*) Feature: the ngx_http_fastcgi_module and the directives:
fastcgi_pass, fastcgi_root, fastcgi_index, fastcgi_params,
fastcgi_connect_timeout, fastcgi_send_timeout, fastcgi_read_timeout,
fastcgi_send_lowat, fastcgi_header_buffer_size, fastcgi_buffers,
fastcgi_busy_buffers_size, fastcgi_temp_path,
fastcgi_max_temp_file_size, fastcgi_temp_file_write_size,
fastcgi_next_upstream, and fastcgi_x_powered_by.
*) Bugfix: the "[alert] zero size buf" error; bug appeared in 0.1.3.
*) Change: the URI must be specified after the host name in the
proxy_pass directive.
*) Change: the %3F symbol in the URI was considered as the argument
string start.
*) Feature: the unix domain sockets support in the
ngx_http_proxy_module.
*) Feature: the ssl_engine and ssl_ciphers directives.
Thanks to Sergey Skvortsov for SSL-accelerator.
author | Igor Sysoev <http://sysoev.ru> |
---|---|
date | Tue, 18 Jan 2005 00:00:00 +0300 |
parents | 74b1868dd3cd |
children | e1ada20fc595 |
comparison
equal
deleted
inserted
replaced
27:66901c2556fd | 28:7ca9bdc82b3f |
---|---|
191 char *p = conf; | 191 char *p = conf; |
192 | 192 |
193 ssize_t level; | 193 ssize_t level; |
194 ngx_uint_t i, n; | 194 ngx_uint_t i, n; |
195 ngx_str_t *value; | 195 ngx_str_t *value; |
196 ngx_path_t *path, **pp, **slot; | 196 ngx_path_t *path, **slot; |
197 | 197 |
198 slot = (ngx_path_t **) (p + cmd->offset); | 198 slot = (ngx_path_t **) (p + cmd->offset); |
199 | 199 |
200 if (*slot) { | 200 if (*slot) { |
201 return "is duplicate"; | 201 return "is duplicate"; |
207 | 207 |
208 value = cf->args->elts; | 208 value = cf->args->elts; |
209 | 209 |
210 path->name = value[1]; | 210 path->name = value[1]; |
211 path->len = 0; | 211 path->len = 0; |
212 path->gc_handler = (ngx_gc_handler_pt) cmd->post; | 212 path->cleaner = (ngx_gc_handler_pt) cmd->post; |
213 path->conf_file = cf->conf_file->file.name.data; | 213 path->conf_file = cf->conf_file->file.name.data; |
214 path->line = cf->conf_file->line; | 214 path->line = cf->conf_file->line; |
215 | 215 |
216 for (i = 0, n = 2; n < cf->args->nelts; i++, n++) { | 216 for (i = 0, n = 2; n < cf->args->nelts; i++, n++) { |
217 level = ngx_atoi(value[n].data, value[n].len); | 217 level = ngx_atoi(value[n].data, value[n].len); |
225 | 225 |
226 while (i < 3) { | 226 while (i < 3) { |
227 path->level[i++] = 0; | 227 path->level[i++] = 0; |
228 } | 228 } |
229 | 229 |
230 | 230 *slot = path; |
231 pp = cf->cycle->pathes.elts; | 231 |
232 if (ngx_add_path(cf, slot) == NGX_ERROR) { | |
233 return NGX_CONF_ERROR; | |
234 } | |
235 | |
236 return NGX_CONF_OK; | |
237 } | |
238 | |
239 | |
240 ngx_int_t ngx_add_path(ngx_conf_t *cf, ngx_path_t **slot) | |
241 { | |
242 ngx_uint_t i, n; | |
243 ngx_path_t *path, **p; | |
244 | |
245 path = *slot; | |
246 | |
247 p = cf->cycle->pathes.elts; | |
232 for (i = 0; i < cf->cycle->pathes.nelts; i++) { | 248 for (i = 0; i < cf->cycle->pathes.nelts; i++) { |
233 if (pp[i]->name.len == path->name.len | 249 if (p[i]->name.len == path->name.len |
234 && ngx_strcmp(pp[i]->name.data, path->name.data) == 0) | 250 && ngx_strcmp(p[i]->name.data, path->name.data) == 0) |
235 { | 251 { |
236 for (n = 0; n < 3; n++) { | 252 for (n = 0; n < 3; n++) { |
237 if (pp[i]->level[n] != path->level[n]) { | 253 if (p[i]->level[n] != path->level[n]) { |
254 if (path->conf_file == NULL) { | |
255 ngx_log_error(NGX_LOG_EMERG, cf->log, 0, | |
256 "the path name \"%V\" in %s:%ui has " | |
257 "the same name as default path but " | |
258 "the different levels, you need to " | |
259 "define default path in http section", | |
260 &p[i]->name, p[i]->conf_file, p[i]->line); | |
261 return NGX_ERROR; | |
262 } | |
263 | |
238 ngx_conf_log_error(NGX_LOG_EMERG, cf, 0, | 264 ngx_conf_log_error(NGX_LOG_EMERG, cf, 0, |
239 "the same \"%V\" path name in %s:%ui " | 265 "the same path name \"%V\" in %s:%ui " |
240 "has the different levels than", | 266 "has the different levels than", |
241 &pp[i]->name, pp[i]->conf_file, pp[i]->line); | 267 &p[i]->name, p[i]->conf_file, p[i]->line); |
242 return NGX_CONF_ERROR; | 268 return NGX_ERROR; |
243 } | 269 } |
244 | 270 |
245 if (pp[i]->level[n] == 0) { | 271 if (p[i]->level[n] == 0) { |
246 break; | 272 break; |
247 } | 273 } |
248 } | 274 } |
249 | 275 |
250 *slot = pp[i]; | 276 *slot = p[i]; |
251 | 277 |
252 return NGX_CONF_OK; | 278 return NGX_OK; |
253 } | 279 } |
254 } | 280 } |
255 | 281 |
256 *slot = path; | 282 if (!(p = ngx_array_push(&cf->cycle->pathes))) { |
257 | 283 return NGX_ERROR; |
258 | 284 } |
259 if (!(pp = ngx_array_push(&cf->cycle->pathes))) { | 285 |
260 return NGX_CONF_ERROR; | 286 *p = path; |
261 } | 287 |
262 | 288 return NGX_OK; |
263 *pp = path; | |
264 | |
265 return NGX_CONF_OK; | |
266 } | 289 } |
267 | 290 |
268 | 291 |
269 ngx_int_t ngx_create_pathes(ngx_cycle_t *cycle, ngx_uid_t user) | 292 ngx_int_t ngx_create_pathes(ngx_cycle_t *cycle, ngx_uid_t user) |
270 { | 293 { |