Mercurial > hg > nginx
comparison src/http/ngx_http.c @ 6378:0f203a2af17c
Dynamic modules: moved module-related stuff to separate files.
author | Maxim Dounin <mdounin@mdounin.ru> |
---|---|
date | Thu, 04 Feb 2016 18:30:21 +0300 |
parents | ceeb1edb3018 |
children | cf5e822cf470 |
comparison
equal
deleted
inserted
replaced
6377:11e019750adc | 6378:0f203a2af17c |
---|---|
142 *(ngx_http_conf_ctx_t **) conf = ctx; | 142 *(ngx_http_conf_ctx_t **) conf = ctx; |
143 | 143 |
144 | 144 |
145 /* count the number of the http modules and set up their indices */ | 145 /* count the number of the http modules and set up their indices */ |
146 | 146 |
147 ngx_http_max_module = 0; | 147 ngx_http_max_module = ngx_count_modules(cf->cycle, NGX_HTTP_MODULE); |
148 for (m = 0; ngx_modules[m]; m++) { | |
149 if (ngx_modules[m]->type != NGX_HTTP_MODULE) { | |
150 continue; | |
151 } | |
152 | |
153 ngx_modules[m]->ctx_index = ngx_http_max_module++; | |
154 } | |
155 | 148 |
156 | 149 |
157 /* the http main_conf context, it is the same in the all http contexts */ | 150 /* the http main_conf context, it is the same in the all http contexts */ |
158 | 151 |
159 ctx->main_conf = ngx_pcalloc(cf->pool, | 152 ctx->main_conf = ngx_pcalloc(cf->pool, |