From e3cab7675801d224d1d5cdbe7f7b76bbaed97c91 Mon Sep 17 00:00:00 2001 From: Maxim Dounin Date: Tue, 20 Aug 2013 21:11:19 +0400 Subject: Backed out f1a91825730a and 7094bd12c1ff. While ngx_get_full_name() might have a bit more descriptive arguments, the ngx_conf_full_name() is generally easier to use when parsing configuration and limits exposure of cycle->prefix / cycle->conf_prefix details. --- src/http/modules/ngx_http_geo_module.c | 2 +- src/http/modules/ngx_http_log_module.c | 4 +--- src/http/modules/ngx_http_xslt_filter_module.c | 2 +- src/http/modules/perl/ngx_http_perl_module.c | 4 +--- 4 files changed, 4 insertions(+), 8 deletions(-) (limited to 'src/http/modules') diff --git a/src/http/modules/ngx_http_geo_module.c b/src/http/modules/ngx_http_geo_module.c index 711871b6c..34c3b190d 100644 --- a/src/http/modules/ngx_http_geo_module.c +++ b/src/http/modules/ngx_http_geo_module.c @@ -1327,7 +1327,7 @@ ngx_http_geo_include(ngx_conf_t *cf, ngx_http_geo_conf_ctx_t *ctx, ngx_sprintf(file.data, "%V.bin%Z", name); - if (ngx_get_full_name(cf->pool, &cf->cycle->conf_prefix, &file) != NGX_OK) { + if (ngx_conf_full_name(cf->cycle, &file, 1) != NGX_OK) { return NGX_CONF_ERROR; } diff --git a/src/http/modules/ngx_http_log_module.c b/src/http/modules/ngx_http_log_module.c index 505ae3b22..aa6a3fcee 100644 --- a/src/http/modules/ngx_http_log_module.c +++ b/src/http/modules/ngx_http_log_module.c @@ -1134,9 +1134,7 @@ ngx_http_log_set_log(ngx_conf_t *cf, ngx_command_t *cmd, void *conf) } } else { - if (ngx_get_full_name(cf->pool, &cf->cycle->prefix, &value[1]) - != NGX_OK) - { + if (ngx_conf_full_name(cf->cycle, &value[1], 0) != NGX_OK) { return NGX_CONF_ERROR; } diff --git a/src/http/modules/ngx_http_xslt_filter_module.c b/src/http/modules/ngx_http_xslt_filter_module.c index 6bf38285b..9e85693bc 100644 --- a/src/http/modules/ngx_http_xslt_filter_module.c +++ b/src/http/modules/ngx_http_xslt_filter_module.c @@ -892,7 +892,7 @@ ngx_http_xslt_stylesheet(ngx_conf_t *cf, ngx_command_t *cmd, void *conf) ngx_memzero(sheet, sizeof(ngx_http_xslt_sheet_t)); - if (ngx_get_full_name(cf->pool, &cf->cycle->prefix, &value[1]) != NGX_OK) { + if (ngx_conf_full_name(cf->cycle, &value[1], 0) != NGX_OK) { return NGX_CONF_ERROR; } diff --git a/src/http/modules/perl/ngx_http_perl_module.c b/src/http/modules/perl/ngx_http_perl_module.c index a8a418422..90e32e80e 100644 --- a/src/http/modules/perl/ngx_http_perl_module.c +++ b/src/http/modules/perl/ngx_http_perl_module.c @@ -485,9 +485,7 @@ ngx_http_perl_init_interpreter(ngx_conf_t *cf, ngx_http_perl_main_conf_t *pmcf) if (pmcf->modules != NGX_CONF_UNSET_PTR) { m = pmcf->modules->elts; for (i = 0; i < pmcf->modules->nelts; i++) { - if (ngx_get_full_name(cf->pool, &cf->cycle->prefix, &m[i]) - != NGX_OK) - { + if (ngx_conf_full_name(cf->cycle, &m[i], 0) != NGX_OK) { return NGX_CONF_ERROR; } } -- cgit