comparison src/http/ngx_http_core_module.h @ 88:674d333f4296

nginx-0.0.1-2003-05-14-21:13:13 import
author Igor Sysoev <igor@sysoev.ru>
date Wed, 14 May 2003 17:13:13 +0000
parents 5f6d848dcbef
children 29bf798b583f
comparison
equal deleted inserted replaced
87:5f6d848dcbef 88:674d333f4296
48 ngx_str_t name; 48 ngx_str_t name;
49 ngx_http_core_srv_conf_t *core_srv_conf; /* virtual name server conf */ 49 ngx_http_core_srv_conf_t *core_srv_conf; /* virtual name server conf */
50 } ngx_http_server_name_t; 50 } ngx_http_server_name_t;
51 51
52 52
53 #define NGX_HTTP_TYPES_HASH_PRIME 13
54
55 #define ngx_http_types_hash_key(key, ext) \
56 { \
57 int n; \
58 for (key = 0, n = 0; n < ext.len; n++) { \
59 key += ext.data[n]; \
60 } \
61 key %= NGX_HTTP_TYPES_HASH_PRIME; \
62 }
63
64 typedef struct {
65 ngx_str_t exten;
66 ngx_str_t type;
67 } ngx_http_type_t;
53 68
54 69
55 typedef struct { 70 typedef struct {
56 ngx_str_t name; /* location name */ 71 ngx_str_t name; /* location name */
57 void **loc_conf; /* pointer to modules loc_conf, 72 void **loc_conf; /* pointer to modules loc_conf,
58 used in translation handler */ 73 used in translation handler */
59 74
60 int (*handler) (ngx_http_request_t *r); 75 int (*handler) (ngx_http_request_t *r);
61 76
62 ngx_str_t doc_root; /* root */ 77 ngx_str_t doc_root; /* root */
78
79 ngx_array_t *types;
63 80
64 int sendfile; /* sendfile */ 81 int sendfile; /* sendfile */
65 time_t send_timeout; /* send_timeout */ 82 time_t send_timeout; /* send_timeout */
66 size_t send_lowat; /* send_lowa */ 83 size_t send_lowat; /* send_lowa */
67 size_t discarded_buffer_size; /* discarded_buffer_size */ 84 size_t discarded_buffer_size; /* discarded_buffer_size */