aboutsummaryrefslogtreecommitdiff
path: root/src/core/nginx.c
diff options
context:
space:
mode:
authorIgor Sysoev <igor@sysoev.ru>2003-05-14 17:13:13 +0000
committerIgor Sysoev <igor@sysoev.ru>2003-05-14 17:13:13 +0000
commit79a804880ee362a1256e6e8aeadb73f7f5cf0885 (patch)
tree72ab5081ebb0a198288f706be81defbb4664e5ae /src/core/nginx.c
parentd581fd58e11724df8d7a9d748f9fc3ab66911a5f (diff)
downloadnginx-79a804880ee362a1256e6e8aeadb73f7f5cf0885.tar.gz
nginx-79a804880ee362a1256e6e8aeadb73f7f5cf0885.zip
nginx-0.0.1-2003-05-14-21:13:13 import
Diffstat (limited to 'src/core/nginx.c')
-rw-r--r--src/core/nginx.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/core/nginx.c b/src/core/nginx.c
index 7f13a7469..4a22e581f 100644
--- a/src/core/nginx.c
+++ b/src/core/nginx.c
@@ -4,6 +4,7 @@
#include <ngx_config.h>
#include <ngx_core.h>
+#include <ngx_os_init.h>
#include <ngx_string.h>
#include <ngx_errno.h>
#include <ngx_time.h>
@@ -52,6 +53,10 @@ int main(int argc, char *const *argv)
/* STUB */
ngx_log.log_level = NGX_LOG_DEBUG;
+ if (ngx_os_init(&ngx_log) == NGX_ERROR) {
+ exit(1);
+ }
+
ngx_pool = ngx_create_pool(16 * 1024, &ngx_log);
/* */
@@ -67,12 +72,6 @@ int main(int argc, char *const *argv)
#endif
-#if 0
- if (ngx_os_init(&ngx_log) == NGX_ERROR) {
- exit(1);
- }
-#endif
-
ngx_init_array(ngx_listening_sockets, ngx_pool, 10, sizeof(ngx_listen_t),
1);
@@ -86,7 +85,8 @@ int main(int argc, char *const *argv)
ngx_create_array(ngx_pool, 10, sizeof(ngx_str_t)), 1);
conf.pool = ngx_pool;
conf.log = &ngx_log;
- conf.type = NGX_CORE_MODULE_TYPE;
+ conf.module_type = NGX_CORE_MODULE_TYPE;
+ conf.cmd_type = NGX_MAIN_CONF;
conf_file.len = sizeof("nginx.conf") - 1;
conf_file.data = "nginx.conf";