nginx-0.1.45-RELEASE import

    *) Change: the "ssl_engine" directive was canceled in the
       ngx_http_ssl_module and now is introduced at global level.

    *) Bugfix: the responses with SSI subrequests did not transferred via
       SSL connection.

    *) Various bug fixes in the IMAP/POP3 proxy.
diff --git a/src/core/nginx.c b/src/core/nginx.c
index 78e3caa..10db555 100644
--- a/src/core/nginx.c
+++ b/src/core/nginx.c
@@ -118,8 +118,14 @@
     &ngx_core_module_ctx,                  /* module context */
     ngx_core_commands,                     /* module directives */
     NGX_CORE_MODULE,                       /* module type */
+    NULL,                                  /* init master */
     NULL,                                  /* init module */
-    NULL                                   /* init process */
+    NULL,                                  /* init process */
+    NULL,                                  /* init thread */
+    NULL,                                  /* exit thread */
+    NULL,                                  /* exit process */
+    NULL,                                  /* exit master */
+    NGX_MODULE_V1_PADDING
 };
 
 
@@ -153,6 +159,7 @@
         return 1;
     }
 
+    /* STUB */
 #if (NGX_OPENSSL)
     ngx_ssl_init(log);
 #endif
diff --git a/src/core/nginx.h b/src/core/nginx.h
index a24f883..904c2ea 100644
--- a/src/core/nginx.h
+++ b/src/core/nginx.h
@@ -8,7 +8,7 @@
 #define _NGINX_H_INCLUDED_
 
 
-#define NGINX_VER          "nginx/0.1.44"
+#define NGINX_VER          "nginx/0.1.45"
 
 #define NGINX_VAR          "NGINX"
 #define NGX_NEWPID_EXT     ".newbin"
diff --git a/src/core/ngx_conf_file.c b/src/core/ngx_conf_file.c
index 1a66ea9..a536bd6 100644
--- a/src/core/ngx_conf_file.c
+++ b/src/core/ngx_conf_file.c
@@ -31,8 +31,14 @@
     NULL,                                  /* module context */
     ngx_conf_commands,                     /* module directives */
     NGX_CONF_MODULE,                       /* module type */
+    NULL,                                  /* init master */
     NULL,                                  /* init module */
-    NULL                                   /* init process */
+    NULL,                                  /* init process */
+    NULL,                                  /* init thread */
+    NULL,                                  /* exit thread */
+    NULL,                                  /* exit process */
+    NULL,                                  /* exit master */
+    NGX_MODULE_V1_PADDING
 };
 
 
diff --git a/src/core/ngx_conf_file.h b/src/core/ngx_conf_file.h
index 1f4e72c..483852f 100644
--- a/src/core/ngx_conf_file.h
+++ b/src/core/ngx_conf_file.h
@@ -65,8 +65,6 @@
 #define NGX_CONF_BLOCK_DONE  2
 #define NGX_CONF_FILE_DONE   3
 
-#define NGX_MODULE_V1        0, 0, 1, 0, 0
-
 #define NGX_CORE_MODULE      0x45524F43  /* "CORE" */
 #define NGX_CONF_MODULE      0x464E4F43  /* "CONF" */
 
@@ -99,21 +97,42 @@
 };
 
 
+#define NGX_MODULE_V1          0, 0, 1, 0, 0, 0, 0
+#define NGX_MODULE_V1_PADDING  0, 0, 0, 0, 0, 0, 0, 0
+
 struct ngx_module_s {
     ngx_uint_t            ctx_index;
     ngx_uint_t            index;
     ngx_uint_t            version;
+
     ngx_uint_t            spare0;
     ngx_uint_t            spare1;
+    ngx_uint_t            spare2;
+    ngx_uint_t            spare3;
 
     void                 *ctx;
     ngx_command_t        *commands;
     ngx_uint_t            type;
+
+    ngx_int_t           (*init_master)(ngx_log_t *log);
+
     ngx_int_t           (*init_module)(ngx_cycle_t *cycle);
+
     ngx_int_t           (*init_process)(ngx_cycle_t *cycle);
-#if 0
     ngx_int_t           (*init_thread)(ngx_cycle_t *cycle);
-#endif
+    ngx_int_t           (*exit_thread)(ngx_cycle_t *cycle);
+    ngx_int_t           (*exit_process)(ngx_cycle_t *cycle);
+
+    ngx_int_t           (*exit_master)(ngx_cycle_t *cycle);
+
+    uintptr_t             spare_hook0;
+    uintptr_t             spare_hook1;
+    uintptr_t             spare_hook2;
+    uintptr_t             spare_hook3;
+    uintptr_t             spare_hook4;
+    uintptr_t             spare_hook5;
+    uintptr_t             spare_hook6;
+    uintptr_t             spare_hook7;
 };
 
 
diff --git a/src/core/ngx_connection.c b/src/core/ngx_connection.c
index fe75264..c423c05 100644
--- a/src/core/ngx_connection.c
+++ b/src/core/ngx_connection.c
@@ -67,6 +67,7 @@
     ngx_listening_t           *ls;
     struct sockaddr_in        *sin;
 #if (NGX_HAVE_DEFERRED_ACCEPT && defined SO_ACCEPTFILTER)
+    ngx_err_t                  err;
     socklen_t                  aflen;
     struct accept_filter_arg   af;
 #endif
@@ -133,7 +134,13 @@
         if (getsockopt(ls[i].fd, SOL_SOCKET, SO_ACCEPTFILTER, &af, &aflen)
             == -1)
         {
-            ngx_log_error(NGX_LOG_NOTICE, cycle->log, ngx_errno,
+            err = ngx_errno;
+
+            if (err == NGX_EINVAL) {
+                continue;
+            }
+
+            ngx_log_error(NGX_LOG_NOTICE, cycle->log, err,
                           "getsockopt(SO_ACCEPTFILTER) for %V failed, ignored",
                           &ls[i].addr_text);
             continue;
diff --git a/src/core/ngx_log.c b/src/core/ngx_log.c
index efc62f9..905c8a1 100644
--- a/src/core/ngx_log.c
+++ b/src/core/ngx_log.c
@@ -37,8 +37,14 @@
     &ngx_errlog_module_ctx,                /* module context */
     ngx_errlog_commands,                   /* module directives */
     NGX_CORE_MODULE,                       /* module type */
+    NULL,                                  /* init master */
     NULL,                                  /* init module */
-    NULL                                   /* init process */
+    NULL,                                  /* init process */
+    NULL,                                  /* init thread */
+    NULL,                                  /* exit thread */
+    NULL,                                  /* exit process */
+    NULL,                                  /* exit master */
+    NGX_MODULE_V1_PADDING
 };