diff src/http/ngx_http_core_module.h @ 1618:fbf94b8341bf stable-0.5

r1386, r1388, r1389, r1580, r1581 merge: regex in server_name and valid_referers
author Igor Sysoev <igor@sysoev.ru>
date Wed, 07 Nov 2007 13:46:29 +0000
parents cacb565c554e
children 3b7262e720c1
line wrap: on
line diff
--- a/src/http/ngx_http_core_module.h
+++ b/src/http/ngx_http_core_module.h
@@ -151,8 +151,10 @@ typedef struct {
 
 typedef struct {
     in_addr_t                  addr;
+
     /* the default server configuration for this address:port */
     ngx_http_core_srv_conf_t  *core_srv_conf;
+
     ngx_http_virtual_names_t  *virtual_names;
 } ngx_http_in_addr_t;
 
@@ -180,6 +182,11 @@ typedef struct {
 
     ngx_array_t                names;      /* array of ngx_http_server_name_t */
 
+#if (NGX_PCRE)
+    ngx_uint_t                 nregex;
+    ngx_http_server_name_t    *regex;
+#endif
+
     /* the default server configuration for this address:port */
     ngx_http_core_srv_conf_t  *core_srv_conf;
 
@@ -190,10 +197,13 @@ typedef struct {
 } ngx_http_conf_in_addr_t;
 
 
-typedef struct {
+struct ngx_http_server_name_s {
+#if (NGX_PCRE)
+    ngx_regex_t               *regex;
+#endif
+    ngx_http_core_srv_conf_t  *core_srv_conf; /* virtual name server conf */
     ngx_str_t                  name;
-    ngx_http_core_srv_conf_t  *core_srv_conf; /* virtual name server conf */
-} ngx_http_server_name_t;
+};
 
 
 typedef struct {