Mercurial > hg > nginx-vendor-0-8
diff src/core/nginx.c @ 384:12defd37f578 NGINX_0_7_4
nginx 0.7.4
*) Feature: variables support in the "access_log" directive.
*) Feature: the "open_log_file_cache" directive.
*) Feature: the -g switch.
*) Feature: the "Expect" request header line support.
*) Bugfix: large SSI inclusions might be truncated.
author | Igor Sysoev <http://sysoev.ru> |
---|---|
date | Mon, 30 Jun 2008 00:00:00 +0400 |
parents | 984bb0b1399b |
children | 79c5df00501e |
line wrap: on
line diff
--- a/src/core/nginx.c +++ b/src/core/nginx.c @@ -637,8 +637,7 @@ ngx_getopt(ngx_cycle_t *cycle, int argc, case 'c': if (argv[i + 1] == NULL) { ngx_log_error(NGX_LOG_EMERG, cycle->log, 0, - "the option: \"%s\" requires file name", - argv[i]); + "the option \"-c\" requires file name"); return NGX_ERROR; } @@ -646,6 +645,17 @@ ngx_getopt(ngx_cycle_t *cycle, int argc, cycle->conf_file.len = ngx_strlen(cycle->conf_file.data); break; + case 'g': + if (argv[i + 1] == NULL) { + ngx_log_error(NGX_LOG_EMERG, cycle->log, 0, + "the option \"-g\" requires parameter"); + return NGX_ERROR; + } + + cycle->conf_param.data = (u_char *) argv[++i]; + cycle->conf_param.len = ngx_strlen(cycle->conf_param.data); + break; + default: ngx_log_error(NGX_LOG_EMERG, cycle->log, 0, "invalid option: \"%s\"", argv[i]);