forked from yaoweibin/nginx_tcp_proxy_module
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtcp-1.4.7.patch
More file actions
52 lines (41 loc) · 2 KB
/
tcp-1.4.7.patch
File metadata and controls
52 lines (41 loc) · 2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
diff -rupN nginx-1.4.7-original/src/core/ngx_log.c nginx-1.4.7/src/core/ngx_log.c
--- nginx-1.4.7-original/src/core/ngx_log.c 2014-03-18 10:17:10.000000000 -0300
+++ nginx-1.4.7/src/core/ngx_log.c 2014-03-26 15:40:30.493781496 -0300
@@ -67,7 +67,7 @@ static ngx_str_t err_levels[] = {
static const char *debug_levels[] = {
"debug_core", "debug_alloc", "debug_mutex", "debug_event",
- "debug_http", "debug_mail", "debug_mysql"
+ "debug_http", "debug_mail", "debug_mysql", "debug_tcp"
};
diff -rupN nginx-1.4.7-original/src/core/ngx_log.h nginx-1.4.7/src/core/ngx_log.h
--- nginx-1.4.7-original/src/core/ngx_log.h 2014-03-18 10:17:10.000000000 -0300
+++ nginx-1.4.7/src/core/ngx_log.h 2014-03-26 15:41:01.097780601 -0300
@@ -30,6 +30,7 @@
#define NGX_LOG_DEBUG_HTTP 0x100
#define NGX_LOG_DEBUG_MAIL 0x200
#define NGX_LOG_DEBUG_MYSQL 0x400
+#define NGX_LOG_DEBUG_TCP 0x800
/*
* do not forget to update debug_levels[] in src/core/ngx_log.c
@@ -37,7 +38,7 @@
*/
#define NGX_LOG_DEBUG_FIRST NGX_LOG_DEBUG_CORE
-#define NGX_LOG_DEBUG_LAST NGX_LOG_DEBUG_MYSQL
+#define NGX_LOG_DEBUG_LAST NGX_LOG_DEBUG_TCP
#define NGX_LOG_DEBUG_CONNECTION 0x80000000
#define NGX_LOG_DEBUG_ALL 0x7ffffff0
diff -rupN nginx-1.4.7-original/src/event/ngx_event_connect.h nginx-1.4.7/src/event/ngx_event_connect.h
--- nginx-1.4.7-original/src/event/ngx_event_connect.h 2014-03-18 10:17:10.000000000 -0300
+++ nginx-1.4.7/src/event/ngx_event_connect.h 2014-03-26 15:41:38.965779494 -0300
@@ -18,6 +18,7 @@
#define NGX_PEER_NEXT 2
#define NGX_PEER_FAILED 4
+#define NGX_INVALID_CHECK_INDEX (ngx_uint_t)(-1)
typedef struct ngx_peer_connection_s ngx_peer_connection_t;
@@ -43,6 +44,8 @@ struct ngx_peer_connection_s {
ngx_uint_t tries;
+ ngx_uint_t check_index;
+
ngx_event_get_peer_pt get;
ngx_event_free_peer_pt free;
void *data;