comparison src/core/ngx_listen.h @ 3:34a521b1a148

nginx-0.0.1-2002-08-20-18:48:28 import
author Igor Sysoev <igor@sysoev.ru>
date Tue, 20 Aug 2002 14:48:28 +0000
parents 4eff17414a43
children 669801705ab1
comparison
equal deleted inserted replaced
2:ffffe1499bce 3:34a521b1a148
1 #ifndef _NGX_LISTEN_H_INCLUDED_ 1 #ifndef _NGX_LISTEN_H_INCLUDED_
2 #define _NGX_LISTEN_H_INCLUDED_ 2 #define _NGX_LISTEN_H_INCLUDED_
3 3
4 4
5 ngx_socket_t ngx_listen(struct sockaddr *addr, int backlog, 5 #include <ngx_config.h>
6 ngx_log_t *log, char *addr_text); 6 #include <ngx_log.h>
7 #include <ngx_types.h>
8 #include <ngx_socket.h>
9 #include <ngx_connection.h>
10
11 typedef struct {
12 ngx_socket_t fd;
13
14 void *addr;
15 size_t addr_len;
16 char *addr_text;
17
18 int family;
19 int type;
20 int protocol;
21
22 ngx_log_t *log;
23 void *server;
24 int (*handler)(ngx_connection_t *c);
25
26 int backlog;
27
28 unsigned done:1;
29 unsigned close:1;
30 unsigned nonblocking:1;
31 #if 0
32 unsigned overlapped:1;
33 #endif
34 unsigned shared:1; /* shared between threads or processes */
35 #if (HAVE_DEFERRED_ACCEPT)
36 unsigned deferred_accept:1;
37 #endif
38 } ngx_listen_t;
7 39
8 40
9 #endif /* _NGX_LISTEN_H_INCLUDED_ */ 41 #endif /* _NGX_LISTEN_H_INCLUDED_ */