Mercurial > hg > nginx
diff src/core/ngx_file.h @ 155:46eb23d9471d
nginx-0.0.1-2003-10-22-20:38:26 import
author | Igor Sysoev <igor@sysoev.ru> |
---|---|
date | Wed, 22 Oct 2003 16:38:26 +0000 |
parents | 7ebc8b7fb816 |
children | e7e094d34162 |
line wrap: on
line diff
--- a/src/core/ngx_file.h +++ b/src/core/ngx_file.h @@ -34,5 +34,24 @@ int ngx_create_path(ngx_file_t *file, ng void ngx_init_temp_number(); int ngx_next_temp_number(int collision); +char *ngx_conf_set_path_slot(ngx_conf_t *cf, ngx_command_t *cmd, void *conf); + + +#define ngx_conf_merge_path_value(conf, prev, path, l1, l2, l3, pool) \ + if (conf == NULL) { \ + if (prev == NULL) { \ + ngx_test_null(conf, ngx_palloc(pool, sizeof(ngx_path_t)), NULL); \ + conf->name.len = sizeof(path) - 1; \ + conf->name.data = path; \ + conf->level[0] = l1; \ + conf->level[1] = l2; \ + conf->level[2] = l3; \ + conf->len = l1 + l2 + l3 + l1 ? 1:0 + l2 ? 1:0 + l3 ? 1:0; \ + } else { \ + conf = prev; \ + } \ + } + + #endif /* _NGX_FILE_H_INCLUDED_ */