nginx-0.0.1-2002-12-27-19:22:50 import
diff --git a/src/core/nginx.c b/src/core/nginx.c
index 17a3d10..0a0233f 100644
--- a/src/core/nginx.c
+++ b/src/core/nginx.c
@@ -2,6 +2,7 @@
 #include <nginx.h>
 
 #include <ngx_config.h>
+
 #include <ngx_string.h>
 #include <ngx_errno.h>
 #include <ngx_time.h>
@@ -12,6 +13,7 @@
 #include <ngx_server.h>
 #include <ngx_connection.h>
 #include <ngx_listen.h>
+#include <ngx_conf_file.h>
 
 /* STUB */
 #include <ngx_http.h>
@@ -62,6 +64,7 @@
                   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_file.len = sizeof("nginx.conf") - 1;
     conf_file.data = "nginx.conf";
diff --git a/src/core/ngx_config_file.c b/src/core/ngx_conf_file.c
similarity index 98%
rename from src/core/ngx_config_file.c
rename to src/core/ngx_conf_file.c
index 79d7218..6b77121 100644
--- a/src/core/ngx_config_file.c
+++ b/src/core/ngx_conf_file.c
@@ -1,7 +1,7 @@
 
 #include <ngx_config.h>
 #include <ngx_core.h>
-#include <ngx_config_file.h>
+#include <ngx_conf_file.h>
 
 
 static int argument_number[] = {
@@ -75,7 +75,9 @@
         name = (ngx_str_t *) cf->args->elts;
 
         for (i = 0; ngx_modules[i]; i++) {
-            if (cf->type != ngx_modules[i]->type) {
+            if (ngx_modules[i]->type != NULL
+                && ngx_modules[i]->type != cf->type)
+            {
                 continue;
             }
 
@@ -88,7 +90,9 @@
                 if (name->len == cmd->name.len
                     && ngx_strcmp(name->data, cmd->name.data) == 0)
                 {
+
 ngx_log_debug(cf->log, "command '%s'" _ cmd->name.data);
+
                     cmd->set(cf, cmd, NULL);
                 }
 
diff --git a/src/core/ngx_config_file.h b/src/core/ngx_conf_file.h
similarity index 76%
rename from src/core/ngx_config_file.h
rename to src/core/ngx_conf_file.h
index 97a4d2a..cab61a3 100644
--- a/src/core/ngx_config_file.h
+++ b/src/core/ngx_conf_file.h
@@ -1,5 +1,5 @@
-#ifndef _NGX_HTTP_CONFIG_FILE_H_INCLUDED_
-#define _NGX_HTTP_CONFIG_FILE_H_INCLUDED_
+#ifndef _NGX_HTTP_CONF_FILE_H_INCLUDED_
+#define _NGX_HTTP_CONF_FILE_H_INCLUDED_
 
 
 #include <ngx_config.h>
@@ -12,21 +12,25 @@
 #include <ngx_array.h>
 
 
-#define NGX_CONF_NOARGS    1
-#define NGX_CONF_TAKE1     2
-#define NGX_CONF_TAKE2     4
+#define NGX_CONF_NOARGS      1
+#define NGX_CONF_TAKE1       2
+#define NGX_CONF_TAKE2       4
+#define NGX_CONF_ARGS_NUMBER 0x0ffff
+#define NGX_CONF_ANY         0x10000
+#define NGX_CONF_BLOCK       0x20000
 
-#define NGX_CONF_ANY       0x10000
-#define NGX_CONF_BLOCK     0x20000
 
-#define NGX_CONF_UNSET    -1
+#define NGX_CONF_UNSET       -1
 
 
+#define NGX_CONF_ERROR       (char *) -1
+
 #define NGX_CONF_BLOCK_DONE  1
 #define NGX_CONF_FILE_DONE   2
 
 
-#define NGX_CONF_ERROR       (char *) -1
+#define NGX_CORE_MODULE_TYPE 0x45524f43  /* "CORE" */
+
 
 typedef struct ngx_conf_s  ngx_conf_t;
 
@@ -80,4 +84,4 @@
 extern ngx_module_t *ngx_modules[];
 
 
-#endif _NGX_HTTP_CONFIG_FILE_H_INCLUDED_
+#endif _NGX_HTTP_CONF_FILE_H_INCLUDED_
diff --git a/src/core/ngx_modules.c b/src/core/ngx_modules.c
index ad9372b..e07c4e6 100644
--- a/src/core/ngx_modules.c
+++ b/src/core/ngx_modules.c
@@ -1,7 +1,7 @@
 
 #include <ngx_config.h>
 
-#include <ngx_config_file.h>
+#include <ngx_conf_file.h>
 
 
 extern ngx_module_t  ngx_http_header_filter_module;