Mercurial > hg > nginx
changeset 1489:56f1ea5baabb
u_char* is enough to keep file name
author | Igor Sysoev <igor@sysoev.ru> |
---|---|
date | Sat, 15 Sep 2007 17:11:06 +0000 |
parents | 0e66eabd18b5 |
children | 111c571f431c |
files | src/http/ngx_http.c src/http/ngx_http_core_module.c src/http/ngx_http_core_module.h src/http/ngx_http_upstream.c src/http/ngx_http_upstream.h src/http/ngx_http_upstream_round_robin.c |
diffstat | 6 files changed, 10 insertions(+), 10 deletions(-) [+] |
line wrap: on
line diff
--- a/src/http/ngx_http.c Sat Sep 15 16:54:58 2007 +0000 +++ b/src/http/ngx_http.c Sat Sep 15 17:11:06 2007 +0000 @@ -553,8 +553,8 @@ if (in_addr[a].default_server) { ngx_log_error(NGX_LOG_ERR, cf->log, 0, - "the duplicate default server in %V:%d", - &lscf[l].file_name, lscf[l].line); + "the duplicate default server in %s:%ui", + &lscf[l].file_name, lscf[l].line); return NGX_CONF_ERROR; }
--- a/src/http/ngx_http_core_module.c Sat Sep 15 16:54:58 2007 +0000 +++ b/src/http/ngx_http_core_module.c Sat Sep 15 17:11:06 2007 +0000 @@ -2627,7 +2627,7 @@ ls->family = AF_INET; ls->addr = u.addr.in_addr; ls->port = u.port; - ls->file_name = cf->conf_file->file.name; + ls->file_name = cf->conf_file->file.name.data; ls->line = cf->conf_file->line; ls->conf.backlog = NGX_LISTEN_BACKLOG; ls->conf.rcvbuf = -1;
--- a/src/http/ngx_http_core_module.h Sat Sep 15 16:54:58 2007 +0000 +++ b/src/http/ngx_http_core_module.h Sat Sep 15 17:11:06 2007 +0000 @@ -38,8 +38,8 @@ in_port_t port; int family; - ngx_str_t file_name; - ngx_int_t line; + u_char *file_name; + ngx_uint_t line; ngx_http_listen_conf_t conf; } ngx_http_listen_t;
--- a/src/http/ngx_http_upstream.c Sat Sep 15 16:54:58 2007 +0000 +++ b/src/http/ngx_http_upstream.c Sat Sep 15 17:11:06 2007 +0000 @@ -3223,7 +3223,7 @@ ngx_log_error(NGX_LOG_WARN, cf->log, 0, "upstream \"%V\" may not have port %d in %s:%ui", &u->host, uscfp[i]->port, - uscfp[i]->file_name.data, uscfp[i]->line); + uscfp[i]->file_name, uscfp[i]->line); return NULL; } @@ -3247,7 +3247,7 @@ uscf->flags = flags; uscf->host = u->host; - uscf->file_name = cf->conf_file->file.name; + uscf->file_name = cf->conf_file->file.name.data; uscf->line = cf->conf_file->line; uscf->port = u->port; uscf->default_port = u->default_port;
--- a/src/http/ngx_http_upstream.h Sat Sep 15 16:54:58 2007 +0000 +++ b/src/http/ngx_http_upstream.h Sat Sep 15 17:11:06 2007 +0000 @@ -92,7 +92,7 @@ ngx_uint_t flags; ngx_str_t host; - ngx_str_t file_name; + u_char *file_name; ngx_uint_t line; in_port_t port; in_port_t default_port;
--- a/src/http/ngx_http_upstream_round_robin.c Sat Sep 15 16:54:58 2007 +0000 +++ b/src/http/ngx_http_upstream_round_robin.c Sat Sep 15 17:11:06 2007 +0000 @@ -136,7 +136,7 @@ if (us->port == 0 && us->default_port == 0) { ngx_log_error(NGX_LOG_EMERG, cf->log, 0, "no port in upstream \"%V\" in %s:%ui", - &us->host, us->file_name.data, us->line); + &us->host, us->file_name, us->line); return NGX_ERROR; } @@ -149,7 +149,7 @@ if (u.err) { ngx_log_error(NGX_LOG_EMERG, cf->log, 0, "%s in upstream \"%V\" in %s:%ui", - u.err, &us->host, us->file_name.data, us->line); + u.err, &us->host, us->file_name, us->line); } return NGX_ERROR;