diff options
author | Maxim Dounin <mdounin@mdounin.ru> | 2016-02-04 18:30:21 +0300 |
---|---|---|
committer | Maxim Dounin <mdounin@mdounin.ru> | 2016-02-04 18:30:21 +0300 |
commit | 0f67d6355cb365983820d3c268e25424509b2ef6 (patch) | |
tree | 5131f107ccec87cd7df68815da5220d106527070 /src/core/ngx_module.c | |
parent | 798833457018ee8a6274ec78e816f747361c0d47 (diff) | |
download | nginx-0f67d6355cb365983820d3c268e25424509b2ef6.tar.gz nginx-0f67d6355cb365983820d3c268e25424509b2ef6.zip |
Dynamic modules: changed ngx_modules to cycle->modules.
Diffstat (limited to 'src/core/ngx_module.c')
-rw-r--r-- | src/core/ngx_module.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/core/ngx_module.c b/src/core/ngx_module.c index dc4e91f34..df3cfde5d 100644 --- a/src/core/ngx_module.c +++ b/src/core/ngx_module.c @@ -32,9 +32,9 @@ ngx_init_modules(ngx_cycle_t *cycle) { ngx_uint_t i; - for (i = 0; ngx_modules[i]; i++) { - if (ngx_modules[i]->init_module) { - if (ngx_modules[i]->init_module(cycle) != NGX_OK) { + for (i = 0; cycle->modules[i]; i++) { + if (cycle->modules[i]->init_module) { + if (cycle->modules[i]->init_module(cycle) != NGX_OK) { return NGX_ERROR; } } @@ -53,12 +53,12 @@ ngx_count_modules(ngx_cycle_t *cycle, ngx_uint_t type) /* count appropriate modules, set up their indices */ - for (i = 0; ngx_modules[i]; i++) { - if (ngx_modules[i]->type != type) { + for (i = 0; cycle->modules[i]; i++) { + if (cycle->modules[i]->type != type) { continue; } - ngx_modules[i]->ctx_index = max++; + cycle->modules[i]->ctx_index = max++; } return max; |